libperf: library for perf events monitoring
summary
Library libperf copies mature code from perf and currently exposes counting and sampling APIs that let user space create perf_event_attr events, open descriptors via a perf_event_list, and read counters or set up a ring buffer per CPU for samples. Installation uses tools/libperf with make install; examples show creating events, enabling them, reading iterations of counters or iterating ring buffers. A small live tracepoint example (≈260 lines) decodes tracepoint fields. Planned work: perf.data parsing, event-name parsing, sample-parsing and packaging; API gains version symbols for stability.
AI-written summary · about
chapters (9)
- 0:00Introduction
- 0:40What does it do
- 1:45Install
- 2:41Interface
- 3:18Counting interface
- 7:23Sampling interface
- 13:18Example
- 16:13Future interface
- 17:28Packaging
related talks
45mPerformance lab. The power of the perf tool!
45mPerf tools updates and beyond
43mAdvanced System Profiling Tracing and Trace Analysis with Perfetto
29mPerf Support in Xen
45mLinux perf tool metrics
31mFantastic tracepoints and where to find them
45mThe perf Profiler and the JVM (Part 1)
21mperf build IDs
