public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Arnaldo Carvalho de Melo <acme@kernel.org>
To: Yannick Brosseau <scientist@fb.com>
Cc: ak@linux.intel.com, jolsa@kernel.org,
	linux-kernel@vger.kernel.org, Mark Drayton <mbd@fb.com>
Subject: Re: [PATCH] perf script: Add --[no-]-demangle/--[no-]-demangle-kernel
Date: Thu, 27 Aug 2015 11:13:23 -0300	[thread overview]
Message-ID: <20150827141323.GA31339@kernel.org> (raw)
In-Reply-To: <1440616695-32340-1-git-send-email-scientist@fb.com>

Em Wed, Aug 26, 2015 at 12:18:15PM -0700, Yannick Brosseau escreveu:
> From: Mark Drayton <mbd@fb.com>
> 
> Summary: Sometimes when post-processing output from `perf script` one
> does not want to demangle C++ symbol names. Add an option to allow this.
> Also add --[no-]demangle-kernel to be consistent with top/report/probe.
> 
> Signed-off-by: Mark Drayton <mbd@fb.com>
> Signed-off-by: Yannick Brosseau <scientist@fb.com>

Thanks, applied after fixing up it wrt other changes in
builtin-script.c, next time, for new features like this, make sure it
applies to my perf/core branch at:

git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux.git

- Arnaldo

> ---
>  tools/perf/Documentation/perf-script.txt | 7 +++++++
>  tools/perf/builtin-script.c              | 4 ++++
>  2 files changed, 11 insertions(+)
> 
> diff --git a/tools/perf/Documentation/perf-script.txt b/tools/perf/Documentation/perf-script.txt
> index c82df57..347c73a 100644
> --- a/tools/perf/Documentation/perf-script.txt
> +++ b/tools/perf/Documentation/perf-script.txt
> @@ -222,6 +222,13 @@ OPTIONS
>  --show-mmap-events
>  	Display mmap related events (e.g. MMAP, MMAP2).
>  
> +--demangle::
> +	Demangle symbol names to human readable form. It's enabled by default,
> +	disable with --no-demangle.
> +
> +--demangle-kernel::
> +	Demangle kernel symbol names to human readable form (for C++ kernels).
> +
>  --header
>  	Show perf.data header.
>  
> diff --git a/tools/perf/builtin-script.c b/tools/perf/builtin-script.c
> index 24809787..f3b3ba0 100644
> --- a/tools/perf/builtin-script.c
> +++ b/tools/perf/builtin-script.c
> @@ -1622,6 +1622,10 @@ int cmd_script(int argc, const char **argv, const char *prefix __maybe_unused)
>  	OPT_CALLBACK_OPTARG(0, "itrace", &itrace_synth_opts, NULL, "opts",
>  			    "Instruction Tracing options",
>  			    itrace_parse_synth_opts),
> +	OPT_BOOLEAN(0, "demangle", &symbol_conf.demangle,
> +		    "Enable symbol demangling"),
> +	OPT_BOOLEAN(0, "demangle-kernel", &symbol_conf.demangle_kernel,
> +		    "Enable kernel symbol demangling"),
>  	OPT_END()
>  	};
>  	const char * const script_subcommands[] = { "record", "report", NULL };
> -- 
> 2.1.4

  reply	other threads:[~2015-08-27 14:13 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-08-26 19:18 [PATCH] perf script: Add --[no-]-demangle/--[no-]-demangle-kernel Yannick Brosseau
2015-08-27 14:13 ` Arnaldo Carvalho de Melo [this message]
2015-08-31  8:30 ` [tip:perf/core] perf script: Add --[no-]-demangle/--[no-] -demangle-kernel tip-bot for Mark Drayton
  -- strict thread matches above, loose matches on Subject: below --
2015-02-09 17:21 [PATCH] perf script: Add --[no-]-demangle/--[no-]-demangle-kernel Mark Drayton

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=20150827141323.GA31339@kernel.org \
    --to=acme@kernel.org \
    --cc=ak@linux.intel.com \
    --cc=jolsa@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mbd@fb.com \
    --cc=scientist@fb.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox