add PERF_SAMPLE_PERIOD to callbacks
- Dominant language
- C
- Stars
- 22.7k
- Forks
- 4.1k
- Avg merge
- 10d 4h
- Merged PRs (30d)
- 3
Description
perf_event callbacks currently return "(pid, callchain)". Lots more can be added from perf_event_sample_format. How about PERF_SAMPLE_PERIOD? This would also require a means to set it.
period was added in 3.17, and already can be used (via perf inject) to set a duration with a stack sample, which is exposed as the period. I blogged about it here: http://www.brendangregg.com/blog/2015-02-26/linux-perf-off-cpu-flame-graph.html
The use case for eBPF would be the same: being able to expose blocked time with selected stack traces, but doing so much more efficiently (the existing perf technique is usually prohibitively costly).
If it's easy, I'd also add PERF_SAMPLE_TIME and PERF_SAMPLE_CPU.
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.