perf trace: Count number of events for each thread and globally
authorArnaldo Carvalho de Melo <acme@redhat.com>
Wed, 17 Oct 2012 20:09:46 +0000 (17:09 -0300)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Thu, 25 Oct 2012 12:40:37 +0000 (10:40 -0200)
commitefd5745e43f3aabd95d521289e0caa0e30668cf4
treea9ecd2cf333304509e2f2f40ed7734327644a6e5
parentba361c92e73c771fcbbbd24c2c03c322e2de2e31
perf trace: Count number of events for each thread and globally

The nr_events in trace__run was local, but we will need it in other
trace methods, move it to struct trace.

We'll also need the number of events per thread, so introduce a
nr_events method for that in struct thread_trace.

Cc: David Ahern <dsahern@gmail.com>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: Mike Galbraith <efault@gmx.de>
Cc: Namhyung Kim <namhyung@gmail.com>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Stephane Eranian <eranian@google.com>
Link: http://lkml.kernel.org/n/tip-ksutaz0mtejnf7e6az3ca1td@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
tools/perf/builtin-trace.c