Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1341910

[RFC PATCH 0/2] perf tools: Print bpf-output events in 'perf script'

From Wang Nan <wangnan0@huawei.com>
Newsgroups linux.kernel
Subject [RFC PATCH 0/2] perf tools: Print bpf-output events in 'perf script'
Date 2016-02-24 12:30 +0100
Message-ID <r5FNM-3OI-13@gated-at.bofh.it> (permalink)
Organization linux.* mail to news gateway

Show all headers | View raw


Hi Arnaldo and Jiri,

   Glad to see the progress we made today.

   Before you trying libbaleltrace, please consider these two patches,
which allows print BPF output data directly through 'perf script'.
I think it would be useful for people don't have libbabeltrace ready.
With these two patch they can write scripts by their own:

 # ./perf script
          usleep  4882 21384.532523:                       evt:  ffffffff810e97d1 sys_nanosleep ([kernel.kallsyms])
      BPF output: 0000: 52 61 69 73 65 20 61 20  Raise a
                  0008: 42 50 46 20 65 76 65 6e  BPF even
                  0010: 74 21 00 00              t!..
      BPF string: "Raise a BPF event!"

          usleep  4882 21384.632606:                       evt:  ffffffff8105c609 kretprobe_trampoline_holder ([kernel.kallsyms
      BPF output: 0000: 52 61 69 73 65 20 61 20  Raise a
                  0008: 42 50 46 20 65 76 65 6e  BPF even
                  0010: 74 21 00 00              t!..
      BPF string: "Raise a BPF event!"

Thank you.

Wang Nan (2):
  perf tools: Make binary data printer code in trace_event public
    available
  perf script: Print bpf-output events in 'perf script'

 tools/perf/builtin-script.c | 93 ++++++++++++++++++++++++++++++++++++++++++---
 tools/perf/util/debug.c     | 75 +++++++++++++++++++++++-------------
 tools/perf/util/util.c      | 37 ++++++++++++++++++
 tools/perf/util/util.h      | 20 ++++++++++
 4 files changed, 193 insertions(+), 32 deletions(-)

Signed-off-by: Wang Nan <wangnan0@huawei.com>
Cc: Arnaldo Carvalho de Melo <acme@redhat.com>
Cc: Brendan Gregg <brendan.d.gregg@gmail.com>
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Li Zefan <lizefan@huawei.com>
Cc: pi3orama@163.com

-- 
1.8.3.4

Back to linux.kernel | Previous | NextNext in thread | Find similar | Unroll thread


Thread

[RFC PATCH 0/2] perf tools: Print bpf-output events in 'perf script' Wang Nan <wangnan0@huawei.com> - 2016-02-24 12:30 +0100
  [RFC PATCH 1/2] perf tools: Make binary data printer code in trace_event public available Wang Nan <wangnan0@huawei.com> - 2016-02-24 12:30 +0100
    [tip:perf/core] perf tools: Make binary data printer code in  trace_event public available tip-bot for Wang Nan <tipbot@zytor.com> - 2016-02-25 08:50 +0100
  Re: [RFC PATCH 0/2] perf tools: Print bpf-output events in 'perf  script' Arnaldo Carvalho de Melo <acme@kernel.org> - 2016-02-24 16:20 +0100

csiph-web