lkml.org 
[lkml]   [2016]   [Feb]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH 1/6] perf, tools, stat: Handled scaled == -1 case for counters
Date
From: Andi Kleen <ak@linux.intel.com>

Arnaldo pointed out that the earlier
"Move noise/running printing into printout"
change changed behavior for not counted counters. This patch fixes it again.

Signed-off-by: Andi Kleen <ak@linux.intel.com>
---
tools/perf/builtin-stat.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tools/perf/builtin-stat.c b/tools/perf/builtin-stat.c
index 15e4fcf..86289df 100644
--- a/tools/perf/builtin-stat.c
+++ b/tools/perf/builtin-stat.c
@@ -860,7 +860,7 @@ static void printout(int id, int nr, struct perf_evsel *counter, double uval,

nl = new_line_std;

- if (run == 0 || ena == 0) {
+ if (run == 0 || ena == 0 || counter->counts->scaled == -1) {
aggr_printout(counter, id, nr);

fprintf(stat_config.output, "%*s%s",
--
2.5.0
\
 
 \ /
  Last update: 2016-02-18 00:01    [W:0.323 / U:3.316 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site