ark::perf::PerfEventReport
Defined in header “ark/perf/perf_event_report.hh”.
This class will aggregate raw perf data into state suitable for emitting a ’tracer’-style JSON report suitable for viewing in Perfetto or the like.
Methods
-
void add_sched_switch_batch(const PerfEventDataBatch & batch)
Adds in a data batch to the report. These will be decoded and stored in the report for later emission. It’s assumed that this batch contains events with ‘sched_switch’ counters. -
std::string tracing_json_report()
Returns a tracing-style JSON report. This will do some level of post-processing on the data collected so far, and then emit the final report as a string.