From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752805AbcERNYO (ORCPT ); Wed, 18 May 2016 09:24:14 -0400 Received: from merlin.infradead.org ([205.233.59.134]:38020 "EHLO merlin.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752494AbcERNYO (ORCPT ); Wed, 18 May 2016 09:24:14 -0400 Date: Wed, 18 May 2016 10:23:58 -0300 From: Arnaldo Carvalho de Melo To: "Wangnan (F)" Cc: Arnaldo Carvalho de Melo , linux-kernel@vger.kernel.org, He Kuang , Jiri Olsa , Masami Hiramatsu , Namhyung Kim , Zefan Li , pi3orama@163.com Subject: Re: [PATCH 02/17] perf tools: Add evlist channel helpers Message-ID: <20160518132358.GB2370@redhat.com> References: <1463126174-119290-1-git-send-email-wangnan0@huawei.com> <1463126174-119290-3-git-send-email-wangnan0@huawei.com> <20160513130516.GH11346@kernel.org> <573BE12F.5020603@huawei.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <573BE12F.5020603@huawei.com> X-Url: http://acmel.wordpress.com User-Agent: Mutt/1.5.20 (2009-12-10) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Em Wed, May 18, 2016 at 11:27:43AM +0800, Wangnan (F) escreveu: > On 2016/5/13 21:05, Arnaldo Carvalho de Melo wrote: > >Em Fri, May 13, 2016 at 07:55:59AM +0000, Wang Nan escreveu: > >> Channels hold different groups of evsels which configured > >> differently. It will be used for overwritable evsels, which allows > >> perf > >why not use multiple evlists? An "evlist" is a "list of evsels", why do > >we need yet another way of grouping evlists? > There's an assumption all over perf that there's only one evlist: in > 'struct record' there's an 'evlist' pointer, in 'struct session' > there's also an 'evlist' pointer. Well, at some point there were none, and multiple tools used multiple ways to deal with lists of events :-) > Trying to change them to an array results in 181 errors, so I think > fundamentally moving to multiple evlists is nearly impossible. Well, in the next paragraph you give it some hope :-) > Now I'm thinking introducing auxiliary evlists to perf record. We > still obey one evlist assumption, only creates separated evlists for > mmap. Ok, that may be the way to go, i.e. linking evlists somehow for some specific use cases, i.e. consuming events from multiple evlists, probably sorting them via the ordered_events class, etc. I have to review this more deeply to try and come with suggestions :-\ - Arnaldo