@@ -1492,6 +1492,7 @@ int cmd_top(int argc, const char **argv)
"Display raw encoding of assembly instructions (default)"),
OPT_BOOLEAN(0, "demangle-kernel", &symbol_conf.demangle_kernel,
"Enable kernel symbol demangling"),
+ OPT_BOOLEAN(0, "no-bpf-event", &top.no_bpf_event, "do not record bpf events"),
OPT_STRING(0, "objdump", &top.annotation_opts.objdump_path, "path",
"objdump binary to use for disassembly and annotations"),
OPT_STRING('M', "disassembler-style", &top.annotation_opts.disassembler_style, "disassembler style",
@@ -1651,6 +1652,8 @@ int cmd_top(int argc, const char **argv)
signal(SIGWINCH, winch_sig);
}
+ top.record_opts.bpf_event = !top.no_bpf_event;
+
status = __cmd_top(&top);
out_delete_evlist:
@@ -32,6 +32,7 @@ struct perf_top {
bool use_tui, use_stdio;
bool vmlinux_warned;
bool dump_symtab;
+ bool no_bpf_event;
struct hist_entry *sym_filter_entry;
struct perf_evsel *sym_evsel;
struct perf_session *session;
bpf events should be tracked by default for perf-top. This patch makes it on by default, and adds option to disable bpf events. Signed-off-by: Song Liu <songliubraving@fb.com> --- tools/perf/builtin-top.c | 3 +++ tools/perf/util/top.h | 1 + 2 files changed, 4 insertions(+)