tools/perf/util/tool.h
Source file repositories/reference/linux-study-clean/tools/perf/util/tool.h
File Facts
- System
- Linux kernel
- Corpus path
tools/perf/util/tool.h- Extension
.h- Size
- 2855 bytes
- Lines
- 119
- Domain
- Support Tooling And Documentation
- Bucket
- tools
- Inferred role
- Support Tooling And Documentation: implementation source
- Status
- source implementation candidate
Why This File Exists
Repository support layer: documentation, build tooling, samples, user-space helper tools, generated initramfs support, licenses, and validation utilities.
- Repository support layer: documentation, build tooling, samples, user-space helper tools, generated initramfs support, licenses, and validation utilities.
- Defines or uses C structs; map object ownership, embedded links, reference counts, and lock ownership.
Dependency Surface
stdbool.hlinux/types.h
Detected Declarations
struct perf_sessionstruct evliststruct evselstruct perf_samplestruct perf_toolstruct machinestruct ordered_eventsstruct perf_toolstruct delegate_toolenum show_feature_header
Annotated Snippet
context_switch,
throttle,
unthrottle,
ksymbol,
bpf,
text_poke;
event_attr_op attr;
event_attr_op event_update;
event_op2 tracing_data;
event_oe finished_round;
event_op2 build_id,
id_index,
auxtrace_info,
auxtrace_error,
time_conv,
thread_map,
cpu_map,
stat_config,
stat,
stat_round,
feature,
finished_init,
bpf_metadata,
schedstat_cpu,
schedstat_domain;
event_op4 compressed;
event_op3 auxtrace;
bool ordered_events;
bool ordering_requires_timestamps;
bool namespace_events;
bool cgroup_events;
bool no_warn;
bool dont_split_sample_group;
bool merge_deferred_callchains;
enum show_feature_header show_feat_hdr;
};
void perf_tool__init(struct perf_tool *tool, bool ordered_events);
bool perf_tool__compressed_is_stub(const struct perf_tool *tool);
int process_event_sample_stub(const struct perf_tool *tool,
union perf_event *event,
struct perf_sample *sample,
struct evsel *evsel,
struct machine *machine);
struct delegate_tool {
/** @tool: The actual tool that calls the delegate. */
struct perf_tool tool;
/** @delegate: The tool that is delegated to. */
struct perf_tool *delegate;
};
void delegate_tool__init(struct delegate_tool *tool, struct perf_tool *delegate);
#endif /* __PERF_TOOL_H */
Annotation
- Immediate include surface: `stdbool.h`, `linux/types.h`.
- Detected declarations: `struct perf_session`, `struct evlist`, `struct evsel`, `struct perf_sample`, `struct perf_tool`, `struct machine`, `struct ordered_events`, `struct perf_tool`, `struct delegate_tool`, `enum show_feature_header`.
- Atlas domain: Support Tooling And Documentation / tools.
- Implementation status: source implementation candidate.
Implementation Notes
- This generated page is the file-by-file coverage layer; curated subsystem chapters should link here when they synthesize a multi-file control flow.
- Core OS pages should be promoted from atlas-only to deep-reviewed when they explain data structures, invariants, locking, lifecycle, and C implementation snippets.
- Driver-family pages are intentionally pattern-oriented unless they are part of the selected PCIe/NVMe representative device path.