aboutsummaryrefslogtreecommitdiffstats
path: root/tools/perf/ui/browsers
diff options
context:
space:
mode:
authorArnaldo Carvalho de Melo <acme@redhat.com>2015-03-19 15:07:21 -0400
committerArnaldo Carvalho de Melo <acme@redhat.com>2015-03-21 13:53:37 -0400
commit70e972788888315851a5c1b4982efbcafcd03b5b (patch)
tree6abdf846461ce84a28223d545cc713e98d1e13bb /tools/perf/ui/browsers
parentf208bd8df08d0659ecd9e09e992c79aab26cddfa (diff)
perf hists browser: Indicate which callchain entries are annotated
Now that we can annotate entries in a callchain, show which ones have an associated symbol and samples, by adding a right arrow just before the symbol name when in verbose mode. To toggle verbose mode press 'V'. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: Borislav Petkov <bp@suse.de> Cc: David Ahern <dsahern@gmail.com> Cc: Don Zickus <dzickus@redhat.com> Cc: Frederic Weisbecker <fweisbec@gmail.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Mike Galbraith <efault@gmx.de> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Link: http://lkml.kernel.org/n/tip-d2rf1p3h5gdp7hdl2gf2bozl@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'tools/perf/ui/browsers')
-rw-r--r--tools/perf/ui/browsers/hists.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/tools/perf/ui/browsers/hists.c b/tools/perf/ui/browsers/hists.c
index cd7350aeb8e7..995b7a8596b1 100644
--- a/tools/perf/ui/browsers/hists.c
+++ b/tools/perf/ui/browsers/hists.c
@@ -511,6 +511,7 @@ static void hist_browser__show_callchain_entry(struct hist_browser *browser,
511{ 511{
512 int color, width; 512 int color, width;
513 char folded_sign = callchain_list__folded(chain); 513 char folded_sign = callchain_list__folded(chain);
514 bool show_annotated = browser->show_dso && chain->ms.sym && symbol__annotation(chain->ms.sym)->src;
514 515
515 color = HE_COLORSET_NORMAL; 516 color = HE_COLORSET_NORMAL;
516 width = browser->b.width - (offset + 2); 517 width = browser->b.width - (offset + 2);
@@ -523,7 +524,8 @@ static void hist_browser__show_callchain_entry(struct hist_browser *browser,
523 ui_browser__set_color(&browser->b, color); 524 ui_browser__set_color(&browser->b, color);
524 hist_browser__gotorc(browser, row, 0); 525 hist_browser__gotorc(browser, row, 0);
525 slsmg_write_nstring(" ", offset); 526 slsmg_write_nstring(" ", offset);
526 slsmg_printf("%c ", folded_sign); 527 slsmg_printf("%c", folded_sign);
528 ui_browser__write_graph(&browser->b, show_annotated ? SLSMG_RARROW_CHAR : ' ');
527 slsmg_write_nstring(str, width); 529 slsmg_write_nstring(str, width);
528} 530}
529 531