linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Greg Price <price@MIT.EDU>
To: Ingo Molnar <mingo@kernel.org>
Cc: Jiri Olsa <jolsa@redhat.com>,
	Arnaldo Carvalho de Melo <acme@ghostprotocols.net>,
	linux-kernel@vger.kernel.org,
	Peter Zijlstra <a.p.zijlstra@chello.nl>,
	Paul Mackerras <paulus@samba.org>, Ingo Molnar <mingo@redhat.com>,
	David Ahern <dsahern@gmail.com>,
	Pekka Enberg <penberg@kernel.org>,
	Namhyung Kim <namhyung@kernel.org>,
	Namhyung Kim <namhyung.kim@lge.com>
Subject: Re: [PATCH] perf report: Add option to collapse undesired parts of call graph
Date: Mon, 24 Jun 2013 19:14:27 -0400	[thread overview]
Message-ID: <20130624231426.GY22203@biohazard-cafe.mit.edu> (raw)
In-Reply-To: <20130624083253.GA28025@gmail.com>

On Mon, Jun 24, 2013 at 10:32:53AM +0200, Ingo Molnar wrote:
> * Jiri Olsa <jolsa@redhat.com> wrote:
> > It could also make sense to allow sorting on this
> > the same way as we do for '-s parent' and report only
> > '[other]' and 'blackbox' entries.
> > 
> > Also I dont like the 'blackbox' option name, it should
> > complement the parent option somehow.. but no idea ;-)
> 
> Looks like a nice feature.

Thanks, good to hear!


> Maybe calling it '--collapse' would be a better name?
> 
> By default the call-graphs are all expanded to maximum. With this option 
> certain function(s) and all their child chains can be collapsed.

Maybe.  But what this does is actually a bit of an inverse of the
collapsing one does in the front-end (with 'C' or with enter, etc.);
unless we have --inverted/-G, the collapsing one can do interactively
is of the various *callers*, recursively, of a function, whereas this
collapses the recursive *callees*.  Or in other words, interactively
one may collapse or expand a subtree of the display; with this option
one collects together and merges all the subtrees that have a given
symbol name at their respective roots.

So this is doing something that can't be achieved by just doing some
grunt work in the front-end as a user, and it might be confusing to
give it the same name as the interactive thing.

If you're investigating the kind of question that --inverted/-G is
good for answering, then this is the same thing one can do with that
grunt work, but in that case the option is less interesting. :)  The
example in my commit message, which comes from a real use case, is
without -G.

Perhaps --coalesce, but that's a little mysterious.  --trim-callees?
--ignore-callees?  --ignore-inside?  --strip-callees?  --trim-inside?


> --parent filters the call-chains, excluding all others that don't include 
> this parent. It might make sense to rename it to --filter?

Sure, maybe so.  I don't have a firm opinion on the name or exact
semantics of --parent.


> It would also be nice if all these visualization variants were available 
> in the GTK front-end.

TBH I'm not really familiar with the GTK front-end, as I mainly use
the TUI.  At a quick trial, it looks like --blackbox has the expected
effect on the display there; though with or without --blackbox I can't
seem to get the entries to expand to show me a call-graph profile, so
it's hard to demonstrate it fully.  Not sure what I may have done
wrong in building or running perf to make that not work (or is that
expected?)

What changes do you have in mind to make these available in the GTK
front-end?


Cheers,
Greg

  reply	other threads:[~2013-06-24 23:14 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-12-07  7:30 [PATCH] perf report: Add option to collapse undesired parts of call graph Greg Price
2013-01-11  5:27 ` Arnaldo Carvalho de Melo
2013-02-25  4:28   ` Greg Price
2013-06-23  3:17   ` Greg Price
2013-06-23 21:53     ` Jiri Olsa
2013-06-24  8:32       ` Ingo Molnar
2013-06-24 23:14         ` Greg Price [this message]
2013-06-25  7:47           ` Ingo Molnar
2013-06-25  8:01             ` Namhyung Kim
2013-06-26 22:41               ` Greg Price
2013-06-24 22:50       ` Greg Price
2013-06-26  1:28     ` Namhyung Kim
2013-06-26 22:25       ` Greg Price
2013-06-27  4:58         ` Namhyung Kim
2013-07-01 14:05           ` Greg Price
2013-07-01 14:08           ` [PATCH] perf report: Fix bug in case "--no-call-graph -p foo" Greg Price
2013-07-01 14:28 [PATCH v2] perf report/top: Add option to collapse undesired parts of call graph Greg Price
2013-07-07 13:13 ` Jiri Olsa
2013-07-08 11:57   ` Greg Price
2013-07-08 16:24     ` Jiri Olsa
2013-07-08 16:47       ` Arnaldo Carvalho de Melo
2013-07-19  7:50     ` [tip:perf/core] " tip-bot for Greg Price

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=20130624231426.GY22203@biohazard-cafe.mit.edu \
    --to=price@mit.edu \
    --cc=a.p.zijlstra@chello.nl \
    --cc=acme@ghostprotocols.net \
    --cc=dsahern@gmail.com \
    --cc=jolsa@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@kernel.org \
    --cc=mingo@redhat.com \
    --cc=namhyung.kim@lge.com \
    --cc=namhyung@kernel.org \
    --cc=paulus@samba.org \
    --cc=penberg@kernel.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;
as well as URLs for NNTP newsgroup(s).