All of lore.kernel.org
 help / color / mirror / Atom feed
From: Arun Sharma <asharma@fb.com>
To: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Namhyung Kim <namhyung.kim@lge.com>,
	<linux-kernel@vger.kernel.org>, Ingo Molnar <mingo@elte.hu>,
	Arnaldo Carvalho de Melo <acme@redhat.com>,
	Mike Galbraith <efault@gmx.de>, Paul Mackerras <paulus@samba.org>,
	Peter Zijlstra <peterz@infradead.org>,
	Stephane Eranian <eranian@google.com>,
	Tom Zanussi <tzanussi@gmail.com>,
	<linux-perf-users@vger.kernel.org>
Subject: Re: [PATCH 0/2] perf: add sort by inclusive time functionality (v2)
Date: Thu, 15 Mar 2012 10:41:11 -0700	[thread overview]
Message-ID: <4F6229B7.2060702@fb.com> (raw)
In-Reply-To: <20120315145033.GB550@somewhere.redhat.com>

On 3/15/12 7:50 AM, Frederic Weisbecker wrote:

>> AFAIK, "sort" here means how perf identifies a sample event from
>> others: "comm" will collect samples have same pid/comm, then "dso"
>> will group samples belong to same library, and "symbol" will group
>> again samples have same symbol name. This is what default sort order
>> (comm,dso,symbol) does.
>
> Right this is about how we group the events into histograms.
> If you sort by dso, you'll have one histogram per dso and events
> will be added to the histogram matching their dso.
>
> Multiple sorting does the same with an "AND" between sort entries.
> If you sort by dso,pid, you'll have one histogram per possible couple
> of (dso,pid).
>
> Say you have dso1, dso2 and pid1 and pid2, then you get 4 possible histograms:
> (dso1,pid1), (dso1,pid2), (dso2,pid1), (dso2,pid2)
> ...assuming that over your events you have all these combinations.
>
> So this is how we group samples into histograms.

Agreed. It's a different sort order, but not necessarily a different 
sort dimension. I'm thinking "group by" vs "order by" in SQL here.

Re: adding a new top level flag, struct option options[] in 
builtin-report.c looks busy (especially for short options. Eg: -i is 
already taken).

I can see parallels between this and sort__branch_mode. Stephane: what 
do you think about putting this in a different namespace?

--sort-mode branch (sort__branch_mode)
--sort-mode inclusive (sort__inclusive_mode)

  -Arun

WARNING: multiple messages have this Message-ID (diff)
From: Arun Sharma <asharma@fb.com>
To: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Namhyung Kim <namhyung.kim@lge.com>,
	linux-kernel@vger.kernel.org, Ingo Molnar <mingo@elte.hu>,
	Arnaldo Carvalho de Melo <acme@redhat.com>,
	Mike Galbraith <efault@gmx.de>, Paul Mackerras <paulus@samba.org>,
	Peter Zijlstra <peterz@infradead.org>,
	Stephane Eranian <eranian@google.com>,
	Tom Zanussi <tzanussi@gmail.com>,
	linux-perf-users@vger.kernel.org
Subject: Re: [PATCH 0/2] perf: add sort by inclusive time functionality (v2)
Date: Thu, 15 Mar 2012 10:41:11 -0700	[thread overview]
Message-ID: <4F6229B7.2060702@fb.com> (raw)
In-Reply-To: <20120315145033.GB550@somewhere.redhat.com>

On 3/15/12 7:50 AM, Frederic Weisbecker wrote:

>> AFAIK, "sort" here means how perf identifies a sample event from
>> others: "comm" will collect samples have same pid/comm, then "dso"
>> will group samples belong to same library, and "symbol" will group
>> again samples have same symbol name. This is what default sort order
>> (comm,dso,symbol) does.
>
> Right this is about how we group the events into histograms.
> If you sort by dso, you'll have one histogram per dso and events
> will be added to the histogram matching their dso.
>
> Multiple sorting does the same with an "AND" between sort entries.
> If you sort by dso,pid, you'll have one histogram per possible couple
> of (dso,pid).
>
> Say you have dso1, dso2 and pid1 and pid2, then you get 4 possible histograms:
> (dso1,pid1), (dso1,pid2), (dso2,pid1), (dso2,pid2)
> ...assuming that over your events you have all these combinations.
>
> So this is how we group samples into histograms.

Agreed. It's a different sort order, but not necessarily a different 
sort dimension. I'm thinking "group by" vs "order by" in SQL here.

Re: adding a new top level flag, struct option options[] in 
builtin-report.c looks busy (especially for short options. Eg: -i is 
already taken).

I can see parallels between this and sort__branch_mode. Stephane: what 
do you think about putting this in a different namespace?

--sort-mode branch (sort__branch_mode)
--sort-mode inclusive (sort__inclusive_mode)

  -Arun

  reply	other threads:[~2012-03-15 17:41 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-03-07 22:41 [PATCH 0/2] perf: add sort by inclusive time functionality (v2) Arun Sharma
2012-03-07 22:41 ` [PATCH 1/2] perf: refactor add_hist_entry() code paths Arun Sharma
2012-03-07 22:41 ` [PATCH 2/2] perf: Add a new sort order: SORT_INCLUSIVE Arun Sharma
2012-03-07 23:13   ` Arun Sharma
2012-03-08  7:22   ` Ingo Molnar
2012-03-12 19:35     ` Arun Sharma
2012-03-12 19:35       ` Arun Sharma
2012-03-08 15:39   ` Frederic Weisbecker
2012-03-08 18:22     ` Arun Sharma
2012-03-13 13:44       ` Frederic Weisbecker
2012-03-08  7:29 ` [PATCH 0/2] perf: add sort by inclusive time functionality (v2) Ingo Molnar
2012-03-08 15:31   ` Frederic Weisbecker
2012-03-08 18:49     ` Arun Sharma
2012-03-08 18:49       ` Arun Sharma
2012-03-12  7:15       ` Namhyung Kim
2012-03-12 18:05         ` Arun Sharma
2012-03-12 18:05           ` Arun Sharma
2012-03-13  1:11           ` Namhyung Kim
2012-03-12  7:43 ` Namhyung Kim
2012-03-12 18:21   ` Arun Sharma
2012-03-12 18:21     ` Arun Sharma
2012-03-12 19:58     ` Arun Sharma
2012-03-12 19:58       ` Arun Sharma
2012-03-13  1:36       ` Namhyung Kim
2012-03-15 14:50         ` Frederic Weisbecker
2012-03-15 17:41           ` Arun Sharma [this message]
2012-03-15 17:41             ` Arun Sharma
2012-03-13  1:16     ` Namhyung Kim
2012-03-13 18:45       ` Arun Sharma
2012-03-13 18:45         ` Arun Sharma

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=4F6229B7.2060702@fb.com \
    --to=asharma@fb.com \
    --cc=acme@redhat.com \
    --cc=efault@gmx.de \
    --cc=eranian@google.com \
    --cc=fweisbec@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-perf-users@vger.kernel.org \
    --cc=mingo@elte.hu \
    --cc=namhyung.kim@lge.com \
    --cc=paulus@samba.org \
    --cc=peterz@infradead.org \
    --cc=tzanussi@gmail.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.