Skip to content

Commit

Permalink
perf branch: Fix interpretation of branch records
Browse files Browse the repository at this point in the history
Commit 93315e4 ("perf/core: Add speculation info to branch
entries") added a new field in between type and new_type. Perf has its
own copy of this struct so update it to match the kernel side.

This doesn't currently cause any issues because new_type is only used by
the Arm BRBE driver which isn't merged yet.

Committer notes:

Is this really an ABI? How are we supposed to deal with old perf.data
files with new tools and vice versa? :-\

Fixes: 93315e4 ("perf/core: Add speculation info to branch entries")
Reviewed-by: Anshuman Khandual <[email protected]>
Signed-off-by: James Clark <[email protected]>
Acked-by: Namhyung Kim <[email protected]>
Cc: Alexander Shishkin <[email protected]>
Cc: Ingo Molnar <[email protected]>
Cc: Jiri Olsa <[email protected]>
Cc: Mark Rutland <[email protected]>
Cc: Peter Zijlstra <[email protected]>
Cc: Sandipan Das <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Arnaldo Carvalho de Melo <[email protected]>
  • Loading branch information
James-A-Clark authored and acmel committed Dec 5, 2022
1 parent 49bd97c commit 20ed9fa
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion tools/perf/util/branch.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,10 @@ struct branch_flags {
u64 abort:1;
u64 cycles:16;
u64 type:4;
u64 spec:2;
u64 new_type:4;
u64 priv:3;
u64 reserved:33;
u64 reserved:31;
};
};
};
Expand Down

0 comments on commit 20ed9fa

Please sign in to comment.