Lines Matching refs:tool

42 	struct perf_tool	tool;  member
70 static int dso__inject_build_id(struct dso *dso, struct perf_tool *tool,
85 static int perf_event__repipe_synth(struct perf_tool *tool, in perf_event__repipe_synth() argument
88 struct perf_inject *inject = container_of(tool, struct perf_inject, in perf_event__repipe_synth()
89 tool); in perf_event__repipe_synth()
94 static int perf_event__repipe_oe_synth(struct perf_tool *tool, in perf_event__repipe_oe_synth() argument
98 return perf_event__repipe_synth(tool, event); in perf_event__repipe_oe_synth()
102 static int perf_event__drop_oe(struct perf_tool *tool __maybe_unused, in perf_event__drop_oe()
113 return perf_event__repipe_synth(session->tool, event); in perf_event__repipe_op2_synth()
121 return perf_event__repipe_synth(session->tool, event); in perf_event__repipe_op4_synth()
124 static int perf_event__repipe_attr(struct perf_tool *tool, in perf_event__repipe_attr() argument
128 struct perf_inject *inject = container_of(tool, struct perf_inject, in perf_event__repipe_attr()
129 tool); in perf_event__repipe_attr()
132 ret = perf_event__process_attr(tool, event, pevlist); in perf_event__repipe_attr()
139 return perf_event__repipe_synth(tool, event); in perf_event__repipe_attr()
142 static int perf_event__repipe_event_update(struct perf_tool *tool, in perf_event__repipe_event_update() argument
146 return perf_event__repipe_synth(tool, event); in perf_event__repipe_event_update()
173 struct perf_tool *tool = session->tool; in perf_event__repipe_auxtrace() local
174 struct perf_inject *inject = container_of(tool, struct perf_inject, in perf_event__repipe_auxtrace()
175 tool); in perf_event__repipe_auxtrace()
220 static int perf_event__repipe(struct perf_tool *tool, in perf_event__repipe() argument
225 return perf_event__repipe_synth(tool, event); in perf_event__repipe()
228 static int perf_event__drop(struct perf_tool *tool __maybe_unused, in perf_event__drop()
236 static int perf_event__drop_aux(struct perf_tool *tool, in perf_event__drop_aux() argument
241 struct perf_inject *inject = container_of(tool, struct perf_inject, tool); in perf_event__drop_aux()
271 typedef int (*inject_handler)(struct perf_tool *tool,
277 static int perf_event__repipe_sample(struct perf_tool *tool, in perf_event__repipe_sample() argument
283 struct perf_inject *inject = container_of(tool, struct perf_inject, in perf_event__repipe_sample()
284 tool); in perf_event__repipe_sample()
288 return f(tool, event, sample, evsel, machine); in perf_event__repipe_sample()
291 build_id__mark_dso_hit(tool, event, sample, evsel, machine); in perf_event__repipe_sample()
296 return perf_event__repipe_synth(tool, event); in perf_event__repipe_sample()
299 static int perf_event__repipe_mmap(struct perf_tool *tool, in perf_event__repipe_mmap() argument
306 err = perf_event__process_mmap(tool, event, sample, machine); in perf_event__repipe_mmap()
307 perf_event__repipe(tool, event, sample, machine); in perf_event__repipe_mmap()
313 static int perf_event__jit_repipe_mmap(struct perf_tool *tool, in perf_event__jit_repipe_mmap() argument
318 struct perf_inject *inject = container_of(tool, struct perf_inject, tool); in perf_event__jit_repipe_mmap()
333 return perf_event__repipe_mmap(tool, event, sample, machine); in perf_event__jit_repipe_mmap()
381 static int perf_event__repipe_buildid_mmap(struct perf_tool *tool, in perf_event__repipe_buildid_mmap() argument
393 dso__inject_build_id(dso, tool, machine, sample->cpumode, 0); in perf_event__repipe_buildid_mmap()
397 return perf_event__repipe(tool, event, sample, machine); in perf_event__repipe_buildid_mmap()
400 static int perf_event__repipe_mmap2(struct perf_tool *tool, in perf_event__repipe_mmap2() argument
407 err = perf_event__process_mmap2(tool, event, sample, machine); in perf_event__repipe_mmap2()
408 perf_event__repipe(tool, event, sample, machine); in perf_event__repipe_mmap2()
426 static int perf_event__jit_repipe_mmap2(struct perf_tool *tool, in perf_event__jit_repipe_mmap2() argument
431 struct perf_inject *inject = container_of(tool, struct perf_inject, tool); in perf_event__jit_repipe_mmap2()
446 return perf_event__repipe_mmap2(tool, event, sample, machine); in perf_event__jit_repipe_mmap2()
450 static int perf_event__repipe_buildid_mmap2(struct perf_tool *tool, in perf_event__repipe_buildid_mmap2() argument
480 dso__inject_build_id(dso, tool, machine, sample->cpumode, in perf_event__repipe_buildid_mmap2()
485 perf_event__repipe(tool, event, sample, machine); in perf_event__repipe_buildid_mmap2()
490 static int perf_event__repipe_fork(struct perf_tool *tool, in perf_event__repipe_fork() argument
497 err = perf_event__process_fork(tool, event, sample, machine); in perf_event__repipe_fork()
498 perf_event__repipe(tool, event, sample, machine); in perf_event__repipe_fork()
503 static int perf_event__repipe_comm(struct perf_tool *tool, in perf_event__repipe_comm() argument
510 err = perf_event__process_comm(tool, event, sample, machine); in perf_event__repipe_comm()
511 perf_event__repipe(tool, event, sample, machine); in perf_event__repipe_comm()
516 static int perf_event__repipe_namespaces(struct perf_tool *tool, in perf_event__repipe_namespaces() argument
521 int err = perf_event__process_namespaces(tool, event, sample, machine); in perf_event__repipe_namespaces()
523 perf_event__repipe(tool, event, sample, machine); in perf_event__repipe_namespaces()
528 static int perf_event__repipe_exit(struct perf_tool *tool, in perf_event__repipe_exit() argument
535 err = perf_event__process_exit(tool, event, sample, machine); in perf_event__repipe_exit()
536 perf_event__repipe(tool, event, sample, machine); in perf_event__repipe_exit()
544 perf_event__repipe_synth(session->tool, event); in perf_event__repipe_tracing_data()
573 static int dso__inject_build_id(struct dso *dso, struct perf_tool *tool, in dso__inject_build_id() argument
588 err = perf_event__synthesize_build_id(tool, dso, cpumode, in dso__inject_build_id()
598 int perf_event__inject_buildid(struct perf_tool *tool, union perf_event *event, in perf_event__inject_buildid() argument
616 dso__inject_build_id(al.map->dso, tool, machine, in perf_event__inject_buildid()
623 perf_event__repipe(tool, event, sample, machine); in perf_event__inject_buildid()
627 static int perf_inject__sched_process_exit(struct perf_tool *tool, in perf_inject__sched_process_exit() argument
633 struct perf_inject *inject = container_of(tool, struct perf_inject, tool); in perf_inject__sched_process_exit()
647 static int perf_inject__sched_switch(struct perf_tool *tool, in perf_inject__sched_switch() argument
653 struct perf_inject *inject = container_of(tool, struct perf_inject, tool); in perf_inject__sched_switch()
656 perf_inject__sched_process_exit(tool, event, sample, evsel, machine); in perf_inject__sched_switch()
671 static int perf_inject__sched_stat(struct perf_tool *tool, in perf_inject__sched_stat() argument
680 struct perf_inject *inject = container_of(tool, struct perf_inject, tool); in perf_inject__sched_stat()
697 build_id__mark_dso_hit(tool, event_sw, &sample_sw, evsel, machine); in perf_inject__sched_stat()
698 return perf_event__repipe(tool, event_sw, &sample_sw, machine); in perf_inject__sched_stat()
720 static int drop_sample(struct perf_tool *tool __maybe_unused, in drop_sample()
734 inject->tool.context_switch = perf_event__drop; in strip_init()
915 inject->tool.mmap = perf_event__repipe_mmap; in __cmd_inject()
916 inject->tool.mmap2 = perf_event__repipe_mmap2; in __cmd_inject()
917 inject->tool.fork = perf_event__repipe_fork; in __cmd_inject()
918 inject->tool.tracing_data = perf_event__repipe_tracing_data; in __cmd_inject()
924 inject->tool.mmap = perf_event__repipe_buildid_mmap; in __cmd_inject()
925 inject->tool.mmap2 = perf_event__repipe_buildid_mmap2; in __cmd_inject()
927 inject->tool.sample = perf_event__inject_buildid; in __cmd_inject()
946 memset(&inject->tool, 0, sizeof(inject->tool)); in __cmd_inject()
947 inject->tool.id_index = perf_event__process_id_index; in __cmd_inject()
948 inject->tool.auxtrace_info = perf_event__process_auxtrace_info; in __cmd_inject()
949 inject->tool.auxtrace = perf_event__process_auxtrace; in __cmd_inject()
950 inject->tool.auxtrace_error = perf_event__process_auxtrace_error; in __cmd_inject()
951 inject->tool.ordered_events = true; in __cmd_inject()
952 inject->tool.ordering_requires_timestamps = true; in __cmd_inject()
956 inject->tool.comm = perf_event__repipe_comm; in __cmd_inject()
957 inject->tool.namespaces = perf_event__repipe_namespaces; in __cmd_inject()
958 inject->tool.exit = perf_event__repipe_exit; in __cmd_inject()
959 inject->tool.id_index = perf_event__process_id_index; in __cmd_inject()
960 inject->tool.auxtrace_info = perf_event__process_auxtrace_info; in __cmd_inject()
961 inject->tool.auxtrace = perf_event__process_auxtrace; in __cmd_inject()
962 inject->tool.aux = perf_event__drop_aux; in __cmd_inject()
963 inject->tool.itrace_start = perf_event__drop_aux; in __cmd_inject()
964 inject->tool.aux_output_hw_id = perf_event__drop_aux; in __cmd_inject()
965 inject->tool.ordered_events = true; in __cmd_inject()
966 inject->tool.ordering_requires_timestamps = true; in __cmd_inject()
1028 .tool = { in cmd_inject()
1182 &inject.tool); in cmd_inject()
1203 ret = perf_event__synthesize_for_pipe(&inject.tool, in cmd_inject()
1218 inject.tool.ordered_events = true; in cmd_inject()
1219 inject.tool.ordering_requires_timestamps = true; in cmd_inject()
1223 inject.tool.ordered_events = true; in cmd_inject()
1228 inject.tool.mmap2 = perf_event__jit_repipe_mmap2; in cmd_inject()
1229 inject.tool.mmap = perf_event__jit_repipe_mmap; in cmd_inject()
1230 inject.tool.ordered_events = true; in cmd_inject()
1231 inject.tool.ordering_requires_timestamps = true; in cmd_inject()
1236 inject.tool.finished_round = perf_event__drop_oe; in cmd_inject()