Commit 585d93c5 authored by Taeung Song's avatar Taeung Song Committed by Arnaldo Carvalho de Melo

perf annotate stdio: Fix --show-total-period

We were showing the total number of samples, not the total period as
asked by the user, fix it.
Reported-by: default avatarNamhyung Kim <namhyung@kernel.org>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: Martin Liška <mliska@suse.cz>
Cc: Milian Wolff <milian.wolff@kdab.com>
Link: http://lkml.kernel.org/n/tip-lh2nh89rtqn5x5vbfthw6qml@git.kernel.org
Fixes: 0c4a5bce ("perf annotate: Display total number of samples with --show-total-period")
[ split from a larger patch ]
Signed-off-by: default avatarArnaldo Carvalho de Melo <acme@redhat.com>
parent ecd5f995
...@@ -1143,7 +1143,7 @@ static int disasm_line__print(struct disasm_line *dl, struct symbol *sym, u64 st ...@@ -1143,7 +1143,7 @@ static int disasm_line__print(struct disasm_line *dl, struct symbol *sym, u64 st
if (symbol_conf.show_total_period) if (symbol_conf.show_total_period)
color_fprintf(stdout, color, " %7" PRIu64, color_fprintf(stdout, color, " %7" PRIu64,
sample.nr_samples); sample.period);
else else
color_fprintf(stdout, color, " %7.2f", percent); color_fprintf(stdout, color, " %7.2f", percent);
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment