From: Masami Hiramatsu <mhiramat@kernel.org>
To: Arnaldo Carvalho de Melo <acme@kernel.org>
Cc: linux-kernel@vger.kernel.org, Namhyung Kim <namhyung@kernel.org>,
Peter Zijlstra <peterz@infradead.org>,
Ingo Molnar <mingo@redhat.com>,
Hemant Kumar <hemant@linux.vnet.ibm.com>,
Ananth N Mavinakayanahalli <ananth@linux.vnet.ibm.com>,
Brendan Gregg <brendan.d.gregg@gmail.com>
Subject: Re: [PATCH perf/core v13 06/15] perf buildid-cache: Scan and import user SDT events to probe cache
Date: Tue, 5 Jul 2016 11:08:10 +0900 [thread overview]
Message-ID: <20160705110810.ff660dea69632954ae87643b@kernel.org> (raw)
In-Reply-To: <20160701182201.GP5324@kernel.org>
On Fri, 1 Jul 2016 15:22:01 -0300
Arnaldo Carvalho de Melo <acme@kernel.org> wrote:
> Em Fri, Jul 01, 2016 at 05:04:10PM +0900, Masami Hiramatsu escreveu:
> > From: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com>
> >
> > perf buildid-cache --add <binary> scans given binary and add
> > the SDT events to probe cache. "sdt_" prefix is appended for
> > all SDT providers to avoid event-name clash with other pre-defined
> > events. It is possible to use the cached SDT events as other cached
> > events, via perf probe --add "sdt_<provider>:<event>=<event>".
> >
> > e.g.
> > ----
> > # perf buildid-cache --add /lib/libc-2.17.so
> > # perf probe --cache --list | head -n 5
> > /usr/lib/libc-2.17.so (a6fb821bdf53660eb2c29f778757aef294d3d392):
> > sdt_libc:setjmp=setjmp
> > sdt_libc:longjmp=longjmp
> > sdt_libc:longjmp_target=longjmp_target
> > sdt_libc:memory_heap_new=memory_heap_new
> > # perf probe -x /usr/lib/libc-2.17.so \
> > -a sdt_libc:memory_heap_new=memory_heap_new
>
> Why not remove the need for that build-cache --add? I.e. go straight to:
>
> perf probe -x /usr/lib/libc-2.17.so -a sdt_libc:memory_heap_new=memory_heap_new
>
> And all the various steps above be done automagically?
Ah, this has been done :) Yes, you can do that already.
See commit dd975497ad ("perf probe: Introduce perf_cache interfaces")
which introduces probe cache and it automatically add the target
binary to the buildid-cache.
Thank you,
--
Masami Hiramatsu <mhiramat@kernel.org>
next prev parent reply other threads:[~2016-07-05 2:08 UTC|newest]
Thread overview: 32+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-07-01 8:03 [PATCH perf/core v13 00/15] perf-probe --cache and SDT support Masami Hiramatsu
2016-07-01 8:03 ` [PATCH perf/core v13 01/15] perf probe: Use cache entry if possible Masami Hiramatsu
2016-07-01 13:20 ` Arnaldo Carvalho de Melo
2016-07-05 10:16 ` [tip:perf/core] " tip-bot for Masami Hiramatsu
2016-07-01 8:03 ` [PATCH perf/core v13 02/15] perf probe: Show all cached probes Masami Hiramatsu
2016-07-01 13:51 ` Arnaldo Carvalho de Melo
2016-07-04 2:03 ` Masami Hiramatsu
2016-07-04 2:06 ` [PATCH perf/core] [BUGFIX] perf-probe: Fix to show correct error message for $vars and $params Masami Hiramatsu
2016-07-05 10:17 ` [tip:perf/core] perf probe: Show all cached probes tip-bot for Masami Hiramatsu
2016-07-01 8:03 ` [PATCH perf/core v13 03/15] perf probe: Remove caches when --cache is given Masami Hiramatsu
2016-07-05 10:17 ` [tip:perf/core] " tip-bot for Masami Hiramatsu
2016-07-01 8:03 ` [PATCH perf/core v13 04/15] perf/sdt: ELF support for SDT Masami Hiramatsu
2016-07-01 18:56 ` Arnaldo Carvalho de Melo
2016-07-04 5:25 ` Masami Hiramatsu
2016-07-05 10:18 ` [tip:perf/core] perf sdt: " tip-bot for Hemant Kumar
2016-07-01 8:04 ` [PATCH perf/core v13 05/15] perf probe: Add group name support Masami Hiramatsu
2016-07-05 10:19 ` [tip:perf/core] " tip-bot for Masami Hiramatsu
2016-07-01 8:04 ` [PATCH perf/core v13 06/15] perf buildid-cache: Scan and import user SDT events to probe cache Masami Hiramatsu
2016-07-01 18:22 ` Arnaldo Carvalho de Melo
2016-07-04 2:15 ` Masami Hiramatsu
2016-07-05 2:08 ` Masami Hiramatsu [this message]
2016-07-05 10:19 ` [tip:perf/core] " tip-bot for Masami Hiramatsu
2016-07-01 8:04 ` [PATCH perf/core v13 07/15] perf probe: Accept %sdt and %cached event name Masami Hiramatsu
2016-07-01 8:04 ` [PATCH perf/core v13 08/15] perf-probe: Make --list shows only available cached events Masami Hiramatsu
2016-07-01 8:04 ` [PATCH perf/core v13 09/15] perf: probe-cache: Add for_each_probe_cache_entry() wrapper Masami Hiramatsu
2016-07-01 8:04 ` [PATCH perf/core v13 10/15] perf probe: Allow wildcard for cached events Masami Hiramatsu
2016-07-01 8:04 ` [PATCH perf/core v13 11/15] perf probe: Search SDT/cached event from all probe caches Masami Hiramatsu
2016-07-01 8:05 ` [PATCH perf/core v13 12/15] perf probe: Support @BUILDID or @FILE suffix for SDT events Masami Hiramatsu
2016-07-01 8:05 ` [PATCH perf/core v13 13/15] perf probe: Support a special SDT probe format Masami Hiramatsu
2016-07-01 8:05 ` [PATCH perf/core v13 14/15] perf build: Add sdt feature detection Masami Hiramatsu
2016-07-01 8:05 ` [PATCH perf/core v13 15/15] perf-test: Add a test case for SDT event Masami Hiramatsu
2016-07-01 13:19 ` [PATCH perf/core v13 00/15] perf-probe --cache and SDT support 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=20160705110810.ff660dea69632954ae87643b@kernel.org \
--to=mhiramat@kernel.org \
--cc=acme@kernel.org \
--cc=ananth@linux.vnet.ibm.com \
--cc=brendan.d.gregg@gmail.com \
--cc=hemant@linux.vnet.ibm.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@redhat.com \
--cc=namhyung@kernel.org \
--cc=peterz@infradead.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).