perf stat: Fix per-socket output bug for uncore events
authorStephane Eranian <[email protected]>
Fri, 5 Jul 2013 17:06:45 +0000 (19:06 +0200)
committerArnaldo Carvalho de Melo <[email protected]>
Mon, 8 Jul 2013 21:01:46 +0000 (18:01 -0300)
commit582ec0829b3dd74d8c0f58403a3f9df8cbaa9c7d
treedfc53409cad09fd7c8eccbf5db02ecbd700f2a36
parentf9ceffb605be7b3b3b2a6e6d14dd0d7a97eae580
perf stat: Fix per-socket output bug for uncore events

This patch fixes a problem reported by Andi Kleen on perf
stat when measuring uncore events:

 # perf stat --per-socket -e uncore_pcu/event=0x0/ -I1000  -a sleep 2

It would not report counts for the second socket. That was due to a
cpu mapping bug in print_aggr().

This patch also fixes the socket numbering bug for <not counted>
events.

Reported-by: Andi Kleen <[email protected]>
Signed-off-by: Stephane Eranian <[email protected]>
Tested-by: Andi Kleen <[email protected]>
Cc: Andi Kleen <[email protected]>
Cc: Ingo Molnar <[email protected]>
Cc: Jiri Olsa <[email protected]>
Cc: Namhyung Kim <[email protected]>
Cc: Peter Zijlstra <[email protected]>
Cc: [email protected]
Link: http://lkml.kernel.org/r/20130705170645.GA32519@quad
Signed-off-by: Arnaldo Carvalho de Melo <[email protected]>
tools/perf/builtin-stat.c