Skip to content
Projects

scope_profiler.plotting_scripts.perf_events

Bar charts for built-in Linux perf-event counter totals and ratios.

Functions

NameDescription
available_perf_event_metricsList available raw events and valid derived perf-event ratios.
plot_perf_eventsPlot one raw perf event or derived ratio for every region and rank.

available_perf_event_metricsfunction#

def available_perf_event_metrics(profiling_data: ProfilingResults | Sequence[ProfilingResults]) -> list[str]

List available raw events and valid derived perf-event ratios.

plot_perf_eventsfunction#

def plot_perf_events(profiling_data: ProfilingResults | Sequence[ProfilingResults], metric: str = 'ipc', ranks: list[int] | int | None = None, include: list[str] | str | None = None, exclude: list[str] | str | None = None, labels: Sequence[str] | None = None, filepath: str | None = None, show: bool = False, verbose: bool = True, cmap: str = DEFAULT_CMAP, backend: str = 'matplotlib') -> None

Plot one raw perf event or derived ratio for every region and rank.

metric may be an event name recorded in the run, "ipc" (instructions/cycle), or "cache-misses-per-ki". Derived metrics are calculated from the region’s aggregated counters, not averages of call ratios, which preserves their proper weighting.