From: Namhyung Kim <namhyung@kernel.org>
To: Arnaldo Carvalho de Melo <acme@ghostprotocols.net>
Cc: Ingo Molnar <mingo@kernel.org>,
Peter Zijlstra <peterz@infradead.org>,
Jiri Olsa <jolsa@redhat.com>,
Stephane Eranian <eranian@google.com>,
LKML <linux-kernel@vger.kernel.org>,
Namhyung Kim <namhyung.kim@lge.com>
Subject: Re: [PATCH 01/12] perf tools: Keep group information
Date: Tue, 13 Nov 2012 10:29:53 +0900 [thread overview]
Message-ID: <87pq3imgry.fsf@sejong.aot.lge.com> (raw)
In-Reply-To: <20121112170833.GE18978@ghostprotocols.net> (Arnaldo Carvalho de Melo's message of "Mon, 12 Nov 2012 14:08:33 -0300")
On Mon, 12 Nov 2012 14:08:33 -0300, Arnaldo Carvalho de Melo wrote:
> Em Sat, Nov 10, 2012 at 01:43:23AM +0900, Namhyung Kim escreveu:
>> From: Namhyung Kim <namhyung.kim@lge.com>
>>
>> Add a few of group-related field in struct perf_{evlist,evsel} so that
>> the group information in a evlist can be known easily. It only counts
>> groups which have more than 1 members since leader-only groups are
>> treated as non-group events.
>
> We don't need to add a group_idx, we can get it using evsel->idx -
> evsel->leader->idx, interdiff of this patch to what I think is
> equivalent:
Looks good to me. Just a comment below..
>
> diff -u b/tools/perf/util/evlist.c b/tools/perf/util/evlist.c
> --- b/tools/perf/util/evlist.c
> +++ b/tools/perf/util/evlist.c
> @@ -111,18 +111,16 @@
> void __perf_evlist__set_leader(struct list_head *list)
> {
> struct perf_evsel *evsel, *leader;
> - int count = 0;
>
> leader = list_entry(list->next, struct perf_evsel, node);
> + evsel = list_entry(list->prev, struct perf_evsel, node);
> leader->leader = NULL;
> + leader->nr_members = evsel->idx - leader->idx + 1;
This will lead a off-by-one difference with my patches. I chose to use
0 nr_members for leader-only group. It was used for an additional
allocation of group stats but it seems that it's not needed anymore
with the hist_link change.
Thanks,
Namhyung
next prev parent reply other threads:[~2012-11-13 1:29 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-11-09 16:43 [PATCHSET 00/12] perf report: Add support for event group view (v5) Namhyung Kim
2012-11-09 16:43 ` [PATCH 01/12] perf tools: Keep group information Namhyung Kim
2012-11-12 17:08 ` Arnaldo Carvalho de Melo
2012-11-13 1:29 ` Namhyung Kim [this message]
2012-11-09 16:43 ` [PATCH 02/12] perf header: Add HEADER_GROUP_DESC feature Namhyung Kim
2012-11-12 17:45 ` Arnaldo Carvalho de Melo
2012-11-13 1:51 ` Namhyung Kim
2012-11-09 16:43 ` [PATCH 03/12] perf hists: Collapse group hist_entries to a leader Namhyung Kim
2012-11-09 16:43 ` [PATCH 04/12] perf hists: Maintain total periods of group members in the leader Namhyung Kim
2012-11-09 16:43 ` [PATCH 05/12] perf report: Make another loop for output resorting Namhyung Kim
2012-11-09 16:43 ` [PATCH 06/12] perf ui/hist: Add support for event group view Namhyung Kim
2012-11-09 16:43 ` [PATCH 07/12] perf ui/browser: " Namhyung Kim
2012-11-09 16:43 ` [PATCH 08/12] perf ui/gtk: " Namhyung Kim
2012-11-09 16:43 ` [PATCH 09/12] perf report: Bypass non-leader events when event group is enabled Namhyung Kim
2012-11-09 16:43 ` [PATCH 10/12] perf report: Show group description " Namhyung Kim
2012-11-09 16:43 ` [PATCH 11/12] perf report: Add --group option Namhyung Kim
2012-11-09 16:43 ` [PATCH 12/12] perf report: Add report.group config option Namhyung Kim
-- strict thread matches above, loose matches on Subject: below --
2012-10-23 7:43 [PATCH 00/12] perf report: Add support for event group view (v4) Namhyung Kim
2012-10-23 7:43 ` [PATCH 01/12] perf tools: Keep group information Namhyung Kim
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87pq3imgry.fsf@sejong.aot.lge.com \
--to=namhyung@kernel.org \
--cc=acme@ghostprotocols.net \
--cc=eranian@google.com \
--cc=jolsa@redhat.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@kernel.org \
--cc=namhyung.kim@lge.com \
--cc=peterz@infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Powered by JetHome