path: root/tools/perf/builtin-annotate.c
diff options
authorArnaldo Carvalho de Melo <>2015-08-24 13:33:14 -0300
committerArnaldo Carvalho de Melo <>2015-08-24 13:33:14 -0300
commitc0b4dffbc529244d3e4e3bd392f2bffa2d8531a7 (patch)
treeb38278d90267adfe41667f150c4d21283da0b91b /tools/perf/builtin-annotate.c
parent5839a5506de30c23d4cfaf49755cd294f5c48368 (diff)
perf annotate: Reset the dso find_symbol cache when removing symbols
The 'annotate' tool does some filtering in the entries in a DSO but forgot to reset the cache done in dso__find_symbol(), cauxing a SEGV: [root@zoo ~]# perf annotate netlink_poll perf: Segmentation fault -------- backtrace -------- perf[0x526ceb] /lib64/[0x7faedfbe0960] perf(rb_erase+0x223)[0x499d63] perf[0x4213e9] perf[0x4bc123] perf[0x4bc621] perf[0x4bf26b] perf[0x4bc855] perf(perf_session__process_events+0x340)[0x4bddc0] perf(cmd_annotate+0x6bb)[0x421b5b] perf[0x479063] perf(main+0x60a)[0x42098a] /lib64/[0x7faedfbcbfe0] perf[0x420aa9] [0x0] [root@zoo ~]# Fix it by reseting the find cache when removing symbols. Cc: Adrian Hunter <> Cc: Borislav Petkov <> Cc: David Ahern <> Cc: Frederic Weisbecker <> Cc: Jiri Olsa <> Cc: Namhyung Kim <> Cc: Stephane Eranian <> Fixes: b685ac22b436 ("perf symbols: Add front end cache for DSO symbol lookup") Link: Signed-off-by: Arnaldo Carvalho de Melo <>
Diffstat (limited to 'tools/perf/builtin-annotate.c')
1 files changed, 1 insertions, 0 deletions
diff --git a/tools/perf/builtin-annotate.c b/tools/perf/builtin-annotate.c
index a32a64ef08e2..8edc205ff9a7 100644
--- a/tools/perf/builtin-annotate.c
+++ b/tools/perf/builtin-annotate.c
@@ -67,6 +67,7 @@ static int perf_evsel__add_sample(struct perf_evsel *evsel,
+ dso__reset_find_symbol_cache(al->map->dso);
return 0;