From: Masami Hiramatsu <mhiramat@kernel.org>
To: Alexandre Ghiti <alex@ghiti.fr>
Cc: Peter Zijlstra <peterz@infradead.org>,
Ingo Molnar <mingo@redhat.com>,
Arnaldo Carvalho de Melo <acme@kernel.org>,
Alexander Shishkin <alexander.shishkin@linux.intel.com>,
Jiri Olsa <jolsa@redhat.com>, Namhyung Kim <namhyung@kernel.org>,
Sasha Levin <sashal@kernel.org>,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
linux-kernel@vger.kernel.org
Subject: Re: Perf tool regression from 07d369857808
Date: Fri, 28 Feb 2020 00:25:53 +0900 [thread overview]
Message-ID: <20200228002553.31b82876b705aaabbd717131@kernel.org> (raw)
In-Reply-To: <2bb02f9b-1413-97c3-684b-104a0fab9144@ghiti.fr>
Hi,
On Thu, 27 Feb 2020 13:23:19 +0100
Alexandre Ghiti <alex@ghiti.fr> wrote:
> Hi Masami,
>
> The commit 07d369857808 ("perf probe: Fix wrong address verification)
> found its way in kernel 4.19.98 (and debian 10) and I observed some
> regressions when I try to add probes in shared libraries.
> The symptoms are:
>
> $ perf probe -f --exec=/home/aghiti/lib/libdpuhw.so --add
> 'log_rank_path=log_rank_path rank path:string'
> Failed to find symbol at 0x3bf0
> Error: Failed to add events.
Hm...
>
> Whereas when I revert this patch, on the same shared library:
>
> $ perf probe -f --exec=/home/aghiti/lib/libdpuhw.so --add
> 'log_rank_path=log_rank_path rank path:string'
> Added new event:
> probe_libdpuhw:log_rank_path_4 (on log_rank_path in
> /home/aghiti/lib/libdpuhw.so.2020.1.0 with rank path:string)
>
> You can now use it in all perf tools, such as:
>
> perf record -e probe_libdpuhw:log_rank_path_4 -aR sleep 1
>
> Actually, I noted that this patch reverts a previous patch that stated
> that dwfl_module_addrsym could fail on shared libraries 664fee3dc379
> ("perf probe: Do not use dwfl_module_addrsym if dwarf_diename finds
> symbol name").
Ah, OK. Hmm, actually, the reason why reverted it was the actuall
address of symbol is unclear if the DIE only has address range.
OK, at first try to find entrypc and if not, try dwlf_module_addrsym().
That will be better idea.
Thank you,
--
Masami Hiramatsu <mhiramat@kernel.org>
next prev parent reply other threads:[~2020-02-27 15:26 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-02-27 12:23 Perf tool regression from 07d369857808 Alexandre Ghiti
2020-02-27 15:25 ` Masami Hiramatsu [this message]
2020-02-27 15:42 ` [BUGFIX PATCH] perf probe: Do not depend on dwfl_module_addrsym() Masami Hiramatsu
2020-02-27 16:20 ` Alexandre Ghiti
2020-02-27 23:52 ` Masami Hiramatsu
2020-03-09 13:44 ` Arnaldo Carvalho de Melo
2020-03-19 14:04 ` [tip: perf/urgent] " tip-bot2 for Masami Hiramatsu
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=20200228002553.31b82876b705aaabbd717131@kernel.org \
--to=mhiramat@kernel.org \
--cc=acme@kernel.org \
--cc=alex@ghiti.fr \
--cc=alexander.shishkin@linux.intel.com \
--cc=gregkh@linuxfoundation.org \
--cc=jolsa@redhat.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@redhat.com \
--cc=namhyung@kernel.org \
--cc=peterz@infradead.org \
--cc=sashal@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