Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

perf symbols: Store if there is a filter in place

When setting yup the symbols library we setup several filter lists,
for dsos, comms, symbols, etc, and there is code that, if there are
filters, do certain operations, like recalculate the number of non
filtered histogram entries in the top/report TUI.

But they were considering just the "Zoom" filters, when they need to
take into account as well the above mentioned filters (perf top --comms,
--dsos, etc).

So store in symbol_conf.has_filter true if any of those filters is in
place.

Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: Borislav Petkov <bp@suse.de>
Cc: David Ahern <dsahern@gmail.com>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Stephane Eranian <eranian@google.com>
Link: http://lkml.kernel.org/n/tip-f5edfmhq69vfvs1kmikq1wep@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>

+4 -1
+2
tools/perf/util/symbol.c
··· 1911 1911 pr_err("problems parsing %s list\n", list_name); 1912 1912 return -1; 1913 1913 } 1914 + 1915 + symbol_conf.has_filter = true; 1914 1916 return 0; 1915 1917 } 1916 1918
+2 -1
tools/perf/util/symbol.h
··· 105 105 demangle_kernel, 106 106 filter_relative, 107 107 show_hist_headers, 108 - branch_callstack; 108 + branch_callstack, 109 + has_filter; 109 110 const char *vmlinux_name, 110 111 *kallsyms_name, 111 112 *source_prefix,