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

perf script: Fix vanished idle symbols

Commit 608c34de0b3d ("perf symbols: Mark if a symbol is idle in the
library") causes idle symbols to vanish from perf script output. That is
because print functions suppress symbols marked as 'idle'.

However, suppression of 'idle' functions is only used by 'perf top' and
'perf top' does not use the print functions. Consequently that
functionality can simply be removed from the print functions.

Signed-off-by: Adrian Hunter <adrian.hunter@intel.com>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: Masami Hiramatsu <mhiramat@kernel.org>
Cc: Mathieu Poirier <mathieu.poirier@linaro.org>
Fixes: 608c34de0b3d ("perf symbols: Mark if a symbol is idle in the library")
Link: http://lkml.kernel.org/r/1474641528-18776-4-git-send-email-adrian.hunter@intel.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>

authored by

Adrian Hunter and committed by
Arnaldo Carvalho de Melo
e7a06a53 1e857484

+2 -5
+2 -5
tools/perf/util/evsel_fprintf.c
··· 122 122 if (!node) 123 123 break; 124 124 125 - if (node->sym && node->sym->idle) 126 - goto next; 127 - 128 125 printed += fprintf(fp, "%-*.*s", left_alignment, left_alignment, " "); 129 126 130 127 if (print_ip) ··· 155 158 156 159 if (!print_oneline) 157 160 printed += fprintf(fp, "\n"); 158 - next: 161 + 159 162 callchain_cursor_advance(cursor); 160 163 } 161 164 } ··· 178 181 if (cursor != NULL) { 179 182 printed += sample__fprintf_callchain(sample, left_alignment, 180 183 print_opts, cursor, fp); 181 - } else if (!(al->sym && al->sym->idle)) { 184 + } else { 182 185 printed += fprintf(fp, "%-*.*s", left_alignment, left_alignment, " "); 183 186 184 187 if (print_ip)