linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Martin Liška" <mliska@suse.cz>
To: Arnaldo Carvalho de Melo <acme@kernel.org>
Cc: linux-kernel@vger.kernel.org, linux-perf-users@vger.kernel.org
Subject: [PATCH] perf config: add annotate.demangle{,_kernel}
Date: Fri, 26 Feb 2021 11:03:14 +0100	[thread overview]
Message-ID: <a4e687b9-f611-1b24-ae7c-2ecd93c42ea8@suse.cz> (raw)
In-Reply-To: <YDVcZJscuKIgShsm@kernel.org>

[-- Attachment #1: Type: text/plain, Size: 230 bytes --]

On 2/23/21 8:49 PM, Arnaldo Carvalho de Melo wrote:
> Please consider making this configurable (if not already) via
> ~/.perfconfig, 'perf config', sure in a followup patch.

I'm doing that in the following patch.

Thanks,
Martin

[-- Attachment #2: 0001-perf-config-add-annotate.demangle-_kernel.patch --]
[-- Type: text/x-patch, Size: 1861 bytes --]

From 797fcd73a3ecdabdf40ae054c1d4c2530fcf8203 Mon Sep 17 00:00:00 2001
From: Martin Liska <mliska@suse.cz>
Date: Fri, 26 Feb 2021 11:01:24 +0100
Subject: [PATCH] perf config: add annotate.demangle{,_kernel}
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

Signed-off-by: Martin Liška <mliska@suse.cz>
---
 tools/perf/Documentation/perf-config.txt | 6 ++++++
 tools/perf/util/annotate.c               | 4 ++++
 2 files changed, 10 insertions(+)

diff --git a/tools/perf/Documentation/perf-config.txt b/tools/perf/Documentation/perf-config.txt
index 153bde14bbe0..154a1ced72b2 100644
--- a/tools/perf/Documentation/perf-config.txt
+++ b/tools/perf/Documentation/perf-config.txt
@@ -393,6 +393,12 @@ annotate.*::
 
 		This option works with tui, stdio2 browsers.
 
+	annotate.demangle::
+		Demangle symbol names to human readable form. Default is 'true'.
+
+	annotate.demangle_kernel::
+		Demangle kernel symbol names to human readable form. Default is 'true'.
+
 hist.*::
 	hist.percentage::
 		This option control the way to calculate overhead of filtered entries -
diff --git a/tools/perf/util/annotate.c b/tools/perf/util/annotate.c
index 80542012ec1b..6e9db717c3d8 100644
--- a/tools/perf/util/annotate.c
+++ b/tools/perf/util/annotate.c
@@ -3142,6 +3142,10 @@ static int annotation__config(const char *var, const char *value, void *data)
 		opt->use_offset = perf_config_bool("use_offset", value);
 	} else if (!strcmp(var, "annotate.disassembler_style")) {
 		opt->disassembler_style = value;
+	} else if (!strcmp(var, "annotate.demangle")) {
+		symbol_conf.demangle = perf_config_bool("demangle", value);
+	} else if (!strcmp(var, "annotate.demangle_kernel")) {
+		symbol_conf.demangle = perf_config_bool("demangle_kernel", value);
 	} else {
 		pr_debug("%s variable unknown, ignoring...", var);
 	}
-- 
2.30.1


  parent reply	other threads:[~2021-02-26 10:06 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-02-22  8:29 [PATCH] perf annotate: add --demangle and --demangle-kernel Martin Liška
2021-02-23 19:49 ` Arnaldo Carvalho de Melo
2021-02-26 10:01   ` Martin Liška
2021-03-07 19:23     ` Martin Liška
2021-03-30  7:41       ` Martin Liška
2021-03-30 15:42         ` Arnaldo Carvalho de Melo
2021-03-30 18:19           ` Martin Liška
2021-03-30 18:23             ` Arnaldo Carvalho de Melo
2021-03-30 18:33             ` Martin Liška
2021-02-26 10:03   ` Martin Liška [this message]
2021-02-26 10:08     ` [PATCH] perf config: add annotate.demangle{,_kernel} Martin Liška
2021-03-06 13:22       ` Arnaldo Carvalho de Melo

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=a4e687b9-f611-1b24-ae7c-2ecd93c42ea8@suse.cz \
    --to=mliska@suse.cz \
    --cc=acme@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-perf-users@vger.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).