}
kvm->session->evlist = kvm->evlist;
perf_session__set_id_hdr_size(kvm->session);
- machine__synthesize_threads(&kvm->session->machines.host, &kvm->tool,
- &kvm->opts.target, kvm->evlist->threads,
- perf_event__process, false);
+ machine__synthesize_threads(&kvm->session->machines.host, &kvm->opts.target,
+ kvm->evlist->threads, false);
err = kvm_live_open_events(kvm);
if (err)
goto out;
perf_event__synthesize_guest_os, tool);
}
- err = machine__synthesize_threads(machine, tool, &opts->target, evsel_list->threads,
- process_synthesized_event, opts->sample_address);
+ err = __machine__synthesize_threads(machine, tool, &opts->target, evsel_list->threads,
+ process_synthesized_event, opts->sample_address);
if (err != 0)
goto out_delete_session;
if (ret)
goto out_delete;
- machine__synthesize_threads(&top->session->machines.host, &top->tool,
- &opts->target, top->evlist->threads,
- perf_event__process, false);
+ machine__synthesize_threads(&top->session->machines.host, &opts->target,
+ top->evlist->threads, false);
ret = perf_top__start_counters(top);
if (ret)
goto out_delete;
if (trace->host == NULL)
return -ENOMEM;
- err = machine__synthesize_threads(trace->host, &trace->tool, &trace->opts.target,
- evlist->threads, trace__tool_process, false);
+ err = __machine__synthesize_threads(trace->host, &trace->tool, &trace->opts.target,
+ evlist->threads, trace__tool_process, false);
if (err)
symbol__exit();
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);
int (*fn)(struct thread *thread, void *p),
void *priv);
-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);
+static inline
+int machine__synthesize_threads(struct machine *machine, struct perf_target *target,
+ struct thread_map *threads, bool data_mmap)
+{
+ return __machine__synthesize_threads(machine, NULL, target, threads,
+ perf_event__process, data_mmap);
+}
+
#endif /* __PERF_MACHINE_H */