]> git.ipfire.org Git - thirdparty/linux.git/commit
perf annotate: Fix register usage in data type profiling
authorNamhyung Kim <namhyung@kernel.org>
Fri, 6 Feb 2026 01:27:43 +0000 (17:27 -0800)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Fri, 6 Feb 2026 21:18:52 +0000 (18:18 -0300)
commit64ea7a4620008652c7f72065ae61efbde7af3ea0
treedc252f1a04f0a32bc1fc26533d3d8b8b65d675b4
parentbb5a920b9099127915706fdd23eb540c9a69c338
perf annotate: Fix register usage in data type profiling

On data type profiling, it tried to match register name with a partial
string.  For example, it allowed to match with "%rbp)" or "%rdi,8)".

But with recent change in the area, it doesn't match anymore and break
the data type profiling.

Let's pass the correct register name by removing the unwanted part.

Add arch__dwarf_regnum() to handle it in a single place.

Closes: 7d3n23li6drroxrdlpxn7ixehdeszkjdftah3zyngjl2qs22ef@yelcjv53v42o
Reported-by: Dmitry Dolgov <9erthalion6@gmail.com>
Reviewed-by: Ian Rogers <irogers@google.com>
Signed-off-by: Namhyung Kim <namhyung@kernel.org>
Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: Ingo Molnar <mingo@kernel.org>
Cc: James Clark <james.clark@linaro.org>
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Zecheng Li <zli94@ncsu.edu>
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
tools/perf/util/annotate.c