perf top: Remove old kernel-only symbol filter
Not needed, we already have code to prune aliases. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Masami Hiramatsu <mhiramat@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-1ysyce7qjgui93gi1efbjwhf@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
This commit is contained in:
parent
608c34de0b
commit
b6220212d4
|
@ -657,31 +657,6 @@ static void *display_thread(void *arg)
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
static int symbol_filter(struct map *map, struct symbol *sym)
|
|
||||||
{
|
|
||||||
const char *name = sym->name;
|
|
||||||
|
|
||||||
if (!__map__is_kernel(map))
|
|
||||||
return 0;
|
|
||||||
/*
|
|
||||||
* ppc64 uses function descriptors and appends a '.' to the
|
|
||||||
* start of every instruction address. Remove it.
|
|
||||||
*/
|
|
||||||
if (name[0] == '.')
|
|
||||||
name++;
|
|
||||||
|
|
||||||
if (!strcmp(name, "_text") ||
|
|
||||||
!strcmp(name, "_etext") ||
|
|
||||||
!strcmp(name, "_sinittext") ||
|
|
||||||
!strncmp("init_module", name, 11) ||
|
|
||||||
!strncmp("cleanup_module", name, 14) ||
|
|
||||||
strstr(name, "_text_start") ||
|
|
||||||
strstr(name, "_text_end"))
|
|
||||||
return 1;
|
|
||||||
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
static int hist_iter__top_callback(struct hist_entry_iter *iter,
|
static int hist_iter__top_callback(struct hist_entry_iter *iter,
|
||||||
struct addr_location *al, bool single,
|
struct addr_location *al, bool single,
|
||||||
void *arg)
|
void *arg)
|
||||||
|
@ -946,8 +921,6 @@ static int __cmd_top(struct perf_top *top)
|
||||||
if (top->session == NULL)
|
if (top->session == NULL)
|
||||||
return -1;
|
return -1;
|
||||||
|
|
||||||
machines__set_symbol_filter(&top->session->machines, symbol_filter);
|
|
||||||
|
|
||||||
if (!objdump_path) {
|
if (!objdump_path) {
|
||||||
ret = perf_env__lookup_objdump(&top->session->header.env);
|
ret = perf_env__lookup_objdump(&top->session->header.env);
|
||||||
if (ret)
|
if (ret)
|
||||||
|
|
Loading…
Reference in New Issue