]> git.baikalelectronics.ru Git - kernel.git/commit
perf stat: Better report failure to collect system wide stats
authorArnaldo Carvalho de Melo <acme@redhat.com>
Mon, 22 Mar 2010 16:10:28 +0000 (13:10 -0300)
committerIngo Molnar <mingo@elte.hu>
Mon, 22 Mar 2010 17:47:35 +0000 (18:47 +0100)
commit11549912c818031fd3f1c028c14ffd9355511e87
tree3e6bf779f4e7f75da57a381fab2aa9f60316fb01
parent65277c0f35ed0fa818ffba8fd8c2ebb131e0c1e5
perf stat: Better report failure to collect system wide stats

Before:

[acme@doppio linux-2.6-tip]$ perf stat -a sleep 1s

 Performance counter stats for 'sleep 1s':

  <not counted>  task-clock-msecs
  <not counted>  context-switches
  <not counted>  CPU-migrations
  <not counted>  page-faults
  <not counted>  cycles
  <not counted>  instructions
  <not counted>  branches
  <not counted>  branch-misses
  <not counted>  cache-references
  <not counted>  cache-misses

    1.016998463  seconds time elapsed

[acme@doppio linux-2.6-tip]$

Now:

[acme@doppio linux-2.6-tip]$ perf stat -a sleep 1s
No permission to collect system-wide stats.
Consider tweaking /proc/sys/kernel/perf_event_paranoid.
[acme@doppio linux-2.6-tip]$

Reported-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Cc: Frédéric Weisbecker <fweisbec@gmail.com>
Cc: Mike Galbraith <efault@gmx.de>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Paul Mackerras <paulus@samba.org>
LKML-Reference: <1269274229-20442-4-git-send-email-acme@infradead.org>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
tools/perf/builtin-stat.c