aboutsummaryrefslogtreecommitdiffstats
path: root/tools/perf/util/annotate.c
diff options
context:
space:
mode:
authorKan Liang <[email protected]>2024-08-13 16:02:02 +0000
committerArnaldo Carvalho de Melo <[email protected]>2024-08-14 13:20:40 +0000
commit3a867a6dadb2d67b85cbf9bc67eca2428075a109 (patch)
treecdcd5fe754d21dba93d6b71988e32ffa901ca669 /tools/perf/util/annotate.c
parentperf report: Remove the first overflow check for branch counters (diff)
downloadkernel-3a867a6dadb2d67b85cbf9bc67eca2428075a109.tar.gz
kernel-3a867a6dadb2d67b85cbf9bc67eca2428075a109.zip
perf evlist: Save branch counters information
The branch counters logging (A.K.A LBR event logging) introduces a per-counter indication of precise event occurrences in LBRs. The kernel only dumps the number of occurrences into a record. The perf tool has to map the number to the corresponding event. Add evlist__update_br_cntr() to go through the evlist to pick the events that are configured to be logged. Assign a logical idx to track them, and add the total number of the events in the leader event. The total number will be used to allocate the space to save the branch counters for a block. The logical idx will be used to locate the corresponding event quickly in the following patches. It only needs to iterate the evlist once. The evsel__has_branch_counters() is also optimized. Reviewed-by: Andi Kleen <[email protected]> Signed-off-by: Kan Liang <[email protected]> Acked-by: Namhyung Kim <[email protected]> Cc: Adrian Hunter <[email protected]> Cc: Ian Rogers <[email protected]> Cc: Ingo Molnar <[email protected]> Cc: Peter Zijlstra <[email protected]> Cc: Stephane Eranian <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Arnaldo Carvalho de Melo <[email protected]>
Diffstat (limited to 'tools/perf/util/annotate.c')
0 files changed, 0 insertions, 0 deletions