perf report: Remove unnecessary check in annotate_browser_write()
In annotate_browser_write(), if (dl->offset != -1 && percent_max != 0.0) { if (percent_max != 0.0) { ... } ... } The second check of (percent_max != 0.0) is not necessary, remove it. Signed-off-by: Yao Jin <yao.jin@linux.intel.com> Acked-by: Milian Wolff <milian.wolff@kdab.com> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Andi Kleen <ak@linux.intel.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Kan Liang <kan.liang@intel.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Yao Jin <yao.jin@linux.intel.com> Link: http://lkml.kernel.org/r/1493909895-9668-2-git-send-email-yao.jin@linux.intel.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
This commit is contained in:
parent
8052bd8243
commit
c564f0db92
|
@ -132,7 +132,6 @@ static void annotate_browser__write(struct ui_browser *browser, void *entry, int
|
|||
}
|
||||
|
||||
if (dl->offset != -1 && percent_max != 0.0) {
|
||||
if (percent_max != 0.0) {
|
||||
for (i = 0; i < ab->nr_events; i++) {
|
||||
ui_browser__set_percent_color(browser,
|
||||
bdl->samples[i].percent,
|
||||
|
@ -145,9 +144,6 @@ static void annotate_browser__write(struct ui_browser *browser, void *entry, int
|
|||
bdl->samples[i].percent);
|
||||
}
|
||||
}
|
||||
} else {
|
||||
ui_browser__write_nstring(browser, " ", 7 * ab->nr_events);
|
||||
}
|
||||
} else {
|
||||
ui_browser__set_percent_color(browser, 0, current_entry);
|
||||
ui_browser__write_nstring(browser, " ", 7 * ab->nr_events);
|
||||
|
|
Loading…
Reference in New Issue