All of lore.kernel.org
 help / color / mirror / Atom feed
From: Arnaldo Carvalho de Melo <acme@redhat.com>
To: Song Liu <songliubraving@fb.com>
Cc: netdev@vger.kernel.org, linux-kernel@vger.kernel.org,
	ast@kernel.org, daniel@iogearbox.net, kernel-team@fb.com,
	peterz@infradead.org, Jiri Olsa <jolsa@kernel.org>,
	Namhyung Kim <namhyung@kernel.org>,
	Andi Kleen <andi@firstfloor.org>,
	Stephane Eranian <eranian@google.com>,
	Arnaldo Carvalho de Melo <acme@kernel.org>
Subject: Re: [PATCH 0/9] perf annotation of BPF programs
Date: Mon, 11 Feb 2019 16:54:00 -0200	[thread overview]
Message-ID: <20190211185400.GA2084@redhat.com> (raw)
In-Reply-To: <20190209011705.2160185-1-songliubraving@fb.com>

Em Fri, Feb 08, 2019 at 05:16:56PM -0800, Song Liu escreveu:
> This series enables annotation of BPF programs in perf.
> 
> perf tool gathers information via sys_bpf and (optionally) stores them in
> perf.data as headers.

Jiri, Stephane, this is the patchkit I mentioned in the context of doing
away with perf.data headers and instead package everything as userspace
PERF_RECORD_ metadata events.

Song, please add Jiri and Namhyung in future perf patchkits, they are
listed as perf tools reviewers in MAINTAINANERS and Jiri also is working
on something directly related.

Thanks,

- Arnaldo
 
> Patch 1/9 fixes a minor issue in kernel;
> Patch 2/9 to 4/9 introduce new helper functions and use them in perf and
>      bpftool;
> Patch 5/9 and 6/9 saves information of bpf program in perf_env;
> Patch 7/9 adds --bpf-event options to perf-top;
> Patch 8/9 enables annotation of bpf programs based on information gathered
>      in 5/9 and 6/9;
> Patch 9/9 handles information of short living BPF program that are loaded
>      during perf-record or perf-top.
> 
> Commands tested during developments are perf-top, perf-record, perf-report,
> and perf-annotate.
> 
> ===================== Note on patch dependency  ========================
> This set has dependency in both bpf-next tree and tip/perf/core. Current
> version is developed on bpf-next tree with the following commits
> cherry-picked from tip/perf/core:
> 
> (from 1/10 to 10/10)
> commit 76193a94522f ("perf, bpf: Introduce PERF_RECORD_KSYMBOL")
> commit d764ac646491 ("tools headers uapi: Sync tools/include/uapi/linux/perf_event.h")
> commit 6ee52e2a3fe4 ("perf, bpf: Introduce PERF_RECORD_BPF_EVENT")
> commit df063c83aa2c ("tools headers uapi: Sync tools/include/uapi/linux/perf_event.h")
> commit 9aa0bfa370b2 ("perf tools: Handle PERF_RECORD_KSYMBOL")
> commit 45178a928a4b ("perf tools: Handle PERF_RECORD_BPF_EVENT")
> commit 7b612e291a5a ("perf tools: Synthesize PERF_RECORD_* for loaded BPF programs")
> commit a40b95bcd30c ("perf top: Synthesize BPF events for pre-existing loaded BPF programs")
> commit 6934058d9fb6 ("bpf: Add module name [bpf] to ksymbols for bpf programs")
> commit 811184fb6977 ("perf bpf: Fix synthesized PERF_RECORD_KSYMBOL/BPF_EVENT")
> ========================================================================
> 
> Song Liu (9):
>   perf, bpf: consider events with attr.bpf_event as side-band events
>   bpf: libbpf: introduce bpf_program__get_prog_info_linear()
>   bpf: bpftool: use bpf_program__get_prog_info_linear() in
>     prog.c:do_dump()
>   perf, bpf: synthesize bpf events with
>     bpf_program__get_prog_info_linear()
>   perf, bpf: save bpf_prog_info in a rbtree in perf_env
>   perf, bpf: save btf in a rbtree in perf_env
>   perf-top: add option --bpf-event
>   perf, bpf: enable annotation of bpf program
>   perf, bpf: save information about short living bpf programs
> 
>  kernel/events/core.c        |   3 +-
>  tools/bpf/bpftool/prog.c    | 266 ++++++---------------------
>  tools/lib/bpf/libbpf.c      | 251 ++++++++++++++++++++++++++
>  tools/lib/bpf/libbpf.h      |  63 +++++++
>  tools/lib/bpf/libbpf.map    |   3 +
>  tools/perf/Makefile.config  |   2 +-
>  tools/perf/builtin-record.c |  15 +-
>  tools/perf/builtin-top.c    |  15 +-
>  tools/perf/util/annotate.c  | 149 ++++++++++++++-
>  tools/perf/util/bpf-event.c | 351 +++++++++++++++++++++++++++---------
>  tools/perf/util/bpf-event.h |  48 ++++-
>  tools/perf/util/dso.c       |   1 +
>  tools/perf/util/dso.h       |  33 ++--
>  tools/perf/util/env.c       | 148 +++++++++++++++
>  tools/perf/util/env.h       |  12 ++
>  tools/perf/util/evlist.c    |  20 ++
>  tools/perf/util/evlist.h    |   2 +
>  tools/perf/util/header.c    | 231 +++++++++++++++++++++++-
>  tools/perf/util/header.h    |   2 +
>  tools/perf/util/symbol.c    |   1 +
>  20 files changed, 1304 insertions(+), 312 deletions(-)
> 
> --
> 2.17.1

  parent reply	other threads:[~2019-02-11 18:54 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-02-09  1:16 [PATCH 0/9] perf annotation of BPF programs Song Liu
2019-02-09  1:16 ` [PATCH 1/9] perf, bpf: consider events with attr.bpf_event as side-band events Song Liu
2019-02-09  1:16 ` [PATCH 2/9] bpf: libbpf: introduce bpf_program__get_prog_info_linear() Song Liu
2019-02-09  1:16 ` [PATCH 3/9] bpf: bpftool: use bpf_program__get_prog_info_linear() in prog.c:do_dump() Song Liu
2019-02-09  1:17 ` [PATCH 4/9] perf, bpf: synthesize bpf events with bpf_program__get_prog_info_linear() Song Liu
2019-02-09  1:17 ` [PATCH 5/9] perf, bpf: save bpf_prog_info in a rbtree in perf_env Song Liu
2019-02-14 12:26   ` Jiri Olsa
2019-02-14 17:01     ` Song Liu
2019-02-14 12:33   ` Jiri Olsa
2019-02-14 17:03     ` Song Liu
2019-02-15  7:41       ` Jiri Olsa
2019-02-11 18:54 ` Arnaldo Carvalho de Melo [this message]
2019-02-11 20:10   ` [PATCH 0/9] perf annotation of BPF programs Song Liu

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=20190211185400.GA2084@redhat.com \
    --to=acme@redhat.com \
    --cc=acme@kernel.org \
    --cc=andi@firstfloor.org \
    --cc=ast@kernel.org \
    --cc=daniel@iogearbox.net \
    --cc=eranian@google.com \
    --cc=jolsa@kernel.org \
    --cc=kernel-team@fb.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=namhyung@kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=peterz@infradead.org \
    --cc=songliubraving@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 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.