2009-07-16 10:54:44

by Anton Blanchard

[permalink] [raw]
Subject: [patch 5/5] perf_counter: Make call graph option consistent

perf record uses -g for logging call graph data but perf report uses -c
to print call graph data. Be consistent and use -g everywhere for call graph
data.

Also update the help text to reflect the current default - fractal,0.5

Signed-off-by: Anton Blanchard <[email protected]>
---

Im not sure if it's too late to make this change, but I've tripped
up a number of times when I cycle between perf record and perf report.

Index: linux.trees.git/tools/perf/builtin-report.c
===================================================================
--- linux.trees.git.orig/tools/perf/builtin-report.c 2009-07-16 19:41:41.000000000 +1000
+++ linux.trees.git/tools/perf/builtin-report.c 2009-07-16 19:41:49.000000000 +1000
@@ -2005,9 +2005,9 @@
"regex filter to identify parent, see: '--sort parent'"),
OPT_BOOLEAN('x', "exclude-other", &exclude_other,
"Only display entries with parent-match"),
- OPT_CALLBACK_DEFAULT('c', "callchain", NULL, "output_type,min_percent",
+ OPT_CALLBACK_DEFAULT('g', "call-graph", NULL, "output_type,min_percent",
"Display callchains using output_type and min percent threshold. "
- "Default: flat,0", &parse_callchain_opt, callchain_default_opt),
+ "Default: fractal,0.5", &parse_callchain_opt, callchain_default_opt),
OPT_STRING('d', "dsos", &dso_list_str, "dso[,dso...]",
"only consider symbols in these dsos"),
OPT_STRING('C', "comms", &comm_list_str, "comm[,comm...]",

--


2009-07-16 14:49:58

by Frederic Weisbecker

[permalink] [raw]
Subject: Re: [patch 5/5] perf_counter: Make call graph option consistent

On Thu, Jul 16, 2009 at 08:42:52PM +1000, Anton Blanchard wrote:
> perf record uses -g for logging call graph data but perf report uses -c
> to print call graph data. Be consistent and use -g everywhere for call graph
> data.
>
> Also update the help text to reflect the current default - fractal,0.5
>
> Signed-off-by: Anton Blanchard <[email protected]>


Thanks!

Acked-by: Frederic Weisbecker <[email protected]>


> ---
>
> Im not sure if it's too late to make this change, but I've tripped
> up a number of times when I cycle between perf record and perf report.
>
> Index: linux.trees.git/tools/perf/builtin-report.c
> ===================================================================
> --- linux.trees.git.orig/tools/perf/builtin-report.c 2009-07-16 19:41:41.000000000 +1000
> +++ linux.trees.git/tools/perf/builtin-report.c 2009-07-16 19:41:49.000000000 +1000
> @@ -2005,9 +2005,9 @@
> "regex filter to identify parent, see: '--sort parent'"),
> OPT_BOOLEAN('x', "exclude-other", &exclude_other,
> "Only display entries with parent-match"),
> - OPT_CALLBACK_DEFAULT('c', "callchain", NULL, "output_type,min_percent",
> + OPT_CALLBACK_DEFAULT('g', "call-graph", NULL, "output_type,min_percent",
> "Display callchains using output_type and min percent threshold. "
> - "Default: flat,0", &parse_callchain_opt, callchain_default_opt),
> + "Default: fractal,0.5", &parse_callchain_opt, callchain_default_opt),
> OPT_STRING('d', "dsos", &dso_list_str, "dso[,dso...]",
> "only consider symbols in these dsos"),
> OPT_STRING('C', "comms", &comm_list_str, "comm[,comm...]",
>
> --
>

2009-07-18 09:51:37

by Anton Blanchard

[permalink] [raw]
Subject: [tip:perfcounters/urgent] perf_counter: Make call graph option consistent

Commit-ID: 1483b19f8f5e8ad0c8816de368b099322dad4db5
Gitweb: http://git.kernel.org/tip/1483b19f8f5e8ad0c8816de368b099322dad4db5
Author: Anton Blanchard <[email protected]>
AuthorDate: Thu, 16 Jul 2009 15:44:29 +0200
Committer: Ingo Molnar <[email protected]>
CommitDate: Sat, 18 Jul 2009 11:21:33 +0200

perf_counter: Make call graph option consistent

perf record uses -g for logging call graph data but perf report
uses -c to print call graph data. Be consistent and use -g
everywhere for call graph data.

Also update the help text to reflect the current default -
fractal,0.5

Signed-off-by: Anton Blanchard <[email protected]>
Acked-by: Frederic Weisbecker <[email protected]>
Signed-off-by: Peter Zijlstra <[email protected]>
LKML-Reference: <[email protected]>
Signed-off-by: Ingo Molnar <[email protected]>


---
tools/perf/builtin-report.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/tools/perf/builtin-report.c b/tools/perf/builtin-report.c
index 4e5cc26..4b980cc 100644
--- a/tools/perf/builtin-report.c
+++ b/tools/perf/builtin-report.c
@@ -1891,9 +1891,9 @@ static const struct option options[] = {
"regex filter to identify parent, see: '--sort parent'"),
OPT_BOOLEAN('x', "exclude-other", &exclude_other,
"Only display entries with parent-match"),
- OPT_CALLBACK_DEFAULT('c', "callchain", NULL, "output_type,min_percent",
+ OPT_CALLBACK_DEFAULT('g', "call-graph", NULL, "output_type,min_percent",
"Display callchains using output_type and min percent threshold. "
- "Default: flat,0", &parse_callchain_opt, callchain_default_opt),
+ "Default: fractal,0.5", &parse_callchain_opt, callchain_default_opt),
OPT_STRING('d', "dsos", &dso_list_str, "dso[,dso...]",
"only consider symbols in these dsos"),
OPT_STRING('C', "comms", &comm_list_str, "comm[,comm...]",