All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jiri Olsa <jolsa@redhat.com>
To: Arnaldo Carvalho de Melo <acme@kernel.org>,
	Ian Rogers <irogers@google.com>
Cc: lkml <linux-kernel@vger.kernel.org>,
	Peter Zijlstra <a.p.zijlstra@chello.nl>,
	Ingo Molnar <mingo@kernel.org>,
	Mark Rutland <mark.rutland@arm.com>,
	Namhyung Kim <namhyung@kernel.org>,
	Alexander Shishkin <alexander.shishkin@linux.intel.com>,
	Michael Petlan <mpetlan@redhat.com>,
	rickyman7@gmail.com
Subject: Re: [RFC 00/10] perf: Add build id parsing fault detection/fix
Date: Tue, 22 Jun 2021 23:19:15 +0200	[thread overview]
Message-ID: <YNJT0wvghSZzPJ8Y@krava> (raw)
In-Reply-To: <YNIobHgfVbiiNscn@kernel.org>

On Tue, Jun 22, 2021 at 03:14:04PM -0300, Arnaldo Carvalho de Melo wrote:
> Em Tue, Jun 22, 2021 at 10:47:54AM -0700, Ian Rogers escreveu:
> > On Tue, Jun 22, 2021 at 10:39 AM Arnaldo Carvalho de Melo
> > <acme@kernel.org> wrote:
> > >
> > > Em Tue, Jun 22, 2021 at 05:39:08PM +0200, Jiri Olsa escreveu:
> > > > hi,
> > > > this *RFC* patchset adds support to detect faults during
> > > > mmap2's build id parsing and a way to fix such maps in
> > > > generated perf.data.
> > > >
> > > > It adds support to record build id faults count for session
> > > > and store it in perf.data and perf inject support to find
> > > > these maps and reads build ids for them in user space.
> > >
> > > > It's probably best explained by the workflow:
> > > >
> > > >   Record data with --buildid-mmap option:
> > > >
> > > >     # perf record --buildid-mmap ...
> > > >     ...
> > > >     [ perf record: Woken up 1 times to write data ]
> > > >     [ perf record: Failed to parse 4 build ids]
> > > >     [ perf record: Captured and wrote 0.008 MB perf.data ]
> > > >
> > > >   Check if there's any build id fault reported:
> > > >
> > > >     # perf report --header-only
> > > >     ...
> > > >     # build id mmap stats: FAULTS 4, LOST 0, NOT FIXED
> > > >
> > > >   There is, check the stats:
> > > >
> > > >     # perf report --stat
> > > >
> > > >     Aggregated stats:
> > > >              TOTAL events:        104
> > > >                       ....
> > > >            BUILD_ID fails:          4  (14.3%)
> > > >
> > > >   Yep, let's fix it:
> > > >
> > > >     # perf inject --buildid-mmap2 -i perf.data -o perf-fixed.data
> > >
> > > Can we make it possible to automate this with --fixup-buildids or a
> > > perfconfig 'record' knob?
> > >
> > > This would entail requesting that build-ids that _fail_ be sent to the
> > > side-band thread we have in 'perf record', this way we wouldn't have to
> > > traverse the whole perf.data file, be it with 'perf-record' at the end
> > > of a session with faulty build ids, or in a similar fashion using 'perf
> > > inject' as you suggest.
> > >
> > > I even think that we can have all these modes and let the user to decide
> > > how important is this for them and how convenient they want the whole
> > > process to be.

right, that might be good to decide first.. because as I said,
I never hit faulted build id, so it probably needs the special
setup you guys are using.. could you try on your setup and check
how many faulted build ids you see?

thanks,
jirka


  reply	other threads:[~2021-06-22 21:19 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-06-22 15:39 [RFC 00/10] perf: Add build id parsing fault detection/fix Jiri Olsa
2021-06-22 15:39 ` [PATCH 01/10] perf: Track build id faults for mmap2 event Jiri Olsa
2021-06-22 15:39 ` [PATCH 02/10] perf: Move build_id_parse to check only regular files Jiri Olsa
2021-06-22 15:39 ` [PATCH 03/10] perf: Add new read_format bit to read build id faults Jiri Olsa
2021-06-22 15:39 ` [PATCH 04/10] perf: Add new read_format bit to read lost events Jiri Olsa
2021-06-22 15:39 ` [PATCH 05/10] tools: Sync perf_event.h uapi Jiri Olsa
2021-06-22 15:39 ` [PATCH 06/10] libperf: Do not allow PERF_FORMAT_GROUP in perf_evsel__read Jiri Olsa
2021-06-22 15:39 ` [PATCH 07/10] perf record: Add support to read build id fails Jiri Olsa
2021-06-22 15:39 ` [PATCH 08/10] perf record: Add new HEADER_BUILD_ID_MMAP feature Jiri Olsa
2021-06-22 15:39 ` [PATCH 09/10] perf report: Display build id fails stats Jiri Olsa
2021-06-22 15:39 ` [PATCH 10/10] perf inject: Add --buildid-mmap2 option to fix failed build ids Jiri Olsa
2021-06-22 17:39 ` [RFC 00/10] perf: Add build id parsing fault detection/fix Arnaldo Carvalho de Melo
2021-06-22 17:47   ` Ian Rogers
2021-06-22 18:14     ` Arnaldo Carvalho de Melo
2021-06-22 21:19       ` Jiri Olsa [this message]
2021-06-23 19:48         ` Namhyung Kim
2021-06-24 11:44           ` Michael Petlan
2021-06-27 17:27             ` Jiri Olsa
2021-06-27 17:25           ` Jiri Olsa
2021-06-28  3:39             ` Namhyung Kim
2021-06-23 20:15 ` Namhyung Kim

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=YNJT0wvghSZzPJ8Y@krava \
    --to=jolsa@redhat.com \
    --cc=a.p.zijlstra@chello.nl \
    --cc=acme@kernel.org \
    --cc=alexander.shishkin@linux.intel.com \
    --cc=irogers@google.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mark.rutland@arm.com \
    --cc=mingo@kernel.org \
    --cc=mpetlan@redhat.com \
    --cc=namhyung@kernel.org \
    --cc=rickyman7@gmail.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.