From: Arnaldo Carvalho de Melo <acme@kernel.org>
To: Namhyung Kim <namhyung@kernel.org>
Cc: Paul McKenney <paulmck@linux.vnet.ibm.com>,
Ingo Molnar <mingo@kernel.org>,
Peter Zijlstra <a.p.zijlstra@chello.nl>,
Jiri Olsa <jolsa@kernel.org>, LKML <linux-kernel@vger.kernel.org>,
Minchan Kim <minchan@kernel.org>,
Taeung Song <treeze.taeung@gmail.com>
Subject: Re: [PATCHSET 0/3] perf diff: Introduce delta-abs compute method
Date: Mon, 6 Feb 2017 09:51:49 -0300 [thread overview]
Message-ID: <20170206125149.GF3762@kernel.org> (raw)
In-Reply-To: <20170206072037.8189-1-namhyung@kernel.org>
Em Mon, Feb 06, 2017 at 04:20:34PM +0900, Namhyung Kim escreveu:
> Hello,
>
> This patchset adds 'delta-abs' compute method to -c/--compute option.
> The 'delta-abs' is same as 'delta' but shows entries with bigger
> absolute delta first instead of sorting numerically. This is only
> useful together with -o option.
>
> Below is default output (-c delta):
>
> $ perf diff -o 1 -c delta | grep -v ^# | head
> 42.22% +4.97% [kernel.kallsyms] [k] cfb_imageblit
> 0.62% +1.23% [kernel.kallsyms] [k] mutex_lock
> +1.15% [kernel.kallsyms] [k] copy_user_generic_string
> 2.40% +0.95% [kernel.kallsyms] [k] bit_putcs
> 0.31% +0.79% [kernel.kallsyms] [k] link_path_walk
> +0.64% [kernel.kallsyms] [k] kmem_cache_alloc
> 0.00% +0.57% [kernel.kallsyms] [k] __rcu_read_unlock
> +0.45% [kernel.kallsyms] [k] alloc_set_pte
> 0.16% +0.45% [kernel.kallsyms] [k] menu_select
> +0.41% ld-2.24.so [.] do_lookup_x
>
> Now with 'delta-abs' it shows entries have bigger delta value either
> positive or negative.
>
> $ perf diff -o 1 -c delta-abs | grep -v ^# | head
> 42.22% +4.97% [kernel.kallsyms] [k] cfb_imageblit
> 12.72% -3.01% [kernel.kallsyms] [k] intel_idle
> 9.72% -1.31% [unknown] [.] 0x0000000000411343
> 0.62% +1.23% [kernel.kallsyms] [k] mutex_lock
> +1.15% [kernel.kallsyms] [k] copy_user_generic_string
> 2.40% +0.95% [kernel.kallsyms] [k] bit_putcs
> 0.31% +0.79% [kernel.kallsyms] [k] link_path_walk
> 1.35% -0.71% [kernel.kallsyms] [k] smp_call_function_single
> +0.64% [kernel.kallsyms] [k] kmem_cache_alloc
> 0.00% +0.57% [kernel.kallsyms] [k] __rcu_read_unlock
>
> The patch 2 and 3 are to add config options to control the default
> behavior of perf diff command. I think that it's worth consider
> changing the default to use 'delta-abs' method since users want to see
> where the difference occurs actually (either positive or negative) IMHO.
I agree on having the default changed to 'delta-abs', Ingo?
Namhyung, and perhaps we should have a single letter option to do that
'| grep -v ^#' bit :-) and perhaps we also should have, for all tools
the equivalent of that "| head", that git log has:
[acme@jouet linux]$ git log --oneline -5
d7cb3a507d23 Merge tag 'perf-core-for-mingo-4.11-20170201' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/core
5443624bedd0 perf/x86/intel/pt: Add format strings for PTWRITE and power event tracing
b05d1093987a perf ftrace: Add ftrace.tracer config option
43d41deb71fe perf tools: Create for_each_event macro for tracepoints iteration
a26305363d4b perf test: Add libbpf pinning test
[acme@jouet linux]$
That '-5' to show just the first 5 lines worth of output.
With all that we would have:
perf diff -o 1 -q10
As the equivalent to "perf diff -o 1 -c delta-abs | grep -v ^# | head".
Ah, adding Paul McKenney to the CC list, he may have something to add
here.
- Arnaldo
> The code is avaiable at 'perf/diff-delta-abs-v1' branch in
>
> git://git.kernel.org/pub/scm/linux/kernel/git/namhyung/linux-perf.git
>
> Thanks,
> Namhyung
>
>
> Namhyung Kim (3):
> perf diff: Add 'delta-abs' compute method
> perf diff: Add diff.order config option
> perf diff: Add diff.compute config option
>
> tools/perf/Documentation/perf-config.txt | 12 +++++
> tools/perf/Documentation/perf-diff.txt | 15 +++++--
> tools/perf/builtin-diff.c | 76 ++++++++++++++++++++++++++++++--
> 3 files changed, 97 insertions(+), 6 deletions(-)
>
> --
> 2.11.0
next prev parent reply other threads:[~2017-02-06 12:51 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-02-06 7:20 [PATCHSET 0/3] perf diff: Introduce delta-abs compute method Namhyung Kim
2017-02-06 7:20 ` [PATCH 1/3] perf diff: Add 'delta-abs' " Namhyung Kim
2017-02-06 7:20 ` [PATCH 2/3] perf diff: Add diff.order config option Namhyung Kim
2017-02-06 9:44 ` Taeung Song
2017-02-06 13:41 ` Namhyung Kim
2017-02-06 7:20 ` [PATCH 3/3] perf diff: Add diff.compute " Namhyung Kim
2017-02-06 10:26 ` [PATCHSET 0/3] perf diff: Introduce delta-abs compute method Jiri Olsa
2017-02-06 13:44 ` Namhyung Kim
2017-02-06 14:14 ` Arnaldo Carvalho de Melo
2017-02-06 12:51 ` Arnaldo Carvalho de Melo [this message]
2017-02-06 14:26 ` Namhyung Kim
2017-02-07 16:02 ` Arnaldo Carvalho de Melo
2017-02-10 7:26 ` 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=20170206125149.GF3762@kernel.org \
--to=acme@kernel.org \
--cc=a.p.zijlstra@chello.nl \
--cc=jolsa@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=minchan@kernel.org \
--cc=mingo@kernel.org \
--cc=namhyung@kernel.org \
--cc=paulmck@linux.vnet.ibm.com \
--cc=treeze.taeung@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.