summaryrefslogtreecommitdiffstats
path: root/tools/perf/util/machine.c
diff options
context:
space:
mode:
authorArnaldo Carvalho de Melo2013-11-11 15:36:12 +0100
committerArnaldo Carvalho de Melo2013-11-11 19:56:40 +0100
commita33fbd56ec83b5421090b4d8f2032f635e6a9488 (patch)
treefe5cbc7363db903130b7c4922c7e6a5204c2f5ed /tools/perf/util/machine.c
parentperf machine: Introduce synthesize_threads method out of open coded equivalent (diff)
downloadkernel-qcow2-linux-a33fbd56ec83b5421090b4d8f2032f635e6a9488.tar.gz
kernel-qcow2-linux-a33fbd56ec83b5421090b4d8f2032f635e6a9488.tar.xz
kernel-qcow2-linux-a33fbd56ec83b5421090b4d8f2032f635e6a9488.zip
perf machine: Simplify synthesize_threads method
Several tools (top, kvm) don't need to be called back to process each of the syntheiszed records, instead relying on the machine__process_event function to change the per machine data structures that represent threads and mmaps, so provide a way to ask for this common idiom. Cc: Adrian Hunter <adrian.hunter@intel.com> 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: Paul Mackerras <paulus@samba.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Link: http://lkml.kernel.org/n/tip-pusqibp8n3c4ynegd1frn4zd@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'tools/perf/util/machine.c')
-rw-r--r--tools/perf/util/machine.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/tools/perf/util/machine.c b/tools/perf/util/machine.c
index 9f2c61d5a9ed..680700b6d779 100644
--- a/tools/perf/util/machine.c
+++ b/tools/perf/util/machine.c
@@ -1395,9 +1395,9 @@ int machine__for_each_thread(struct machine *machine,
return rc;
}
-int machine__synthesize_threads(struct machine *machine, struct perf_tool *tool,
- struct perf_target *target, struct thread_map *threads,
- perf_event__handler_t process, bool data_mmap)
+int __machine__synthesize_threads(struct machine *machine, struct perf_tool *tool,
+ struct perf_target *target, struct thread_map *threads,
+ perf_event__handler_t process, bool data_mmap)
{
if (perf_target__has_task(target))
return perf_event__synthesize_thread_map(tool, threads, process, machine, data_mmap);