Re: [PATCH v1 0/2] perf report: Support annotation of code without symbols

From: Jin, Yao
Date: Thu Feb 20 2020 - 08:50:47 EST




On 2/20/2020 8:06 PM, Jiri Olsa wrote:
On Thu, Feb 20, 2020 at 08:03:18PM +0800, Jin, Yao wrote:


On 2/20/2020 7:56 PM, Jiri Olsa wrote:
On Thu, Feb 20, 2020 at 08:59:00AM +0800, Jin Yao wrote:
For perf report on stripped binaries it is currently impossible to do
annotation. The annotation state is all tied to symbols, but there are
either no symbols, or symbols are not covering all the code.

We should support the annotation functionality even without symbols.

The first patch uses al_addr to print because it's easy to dump
the instructions from this address in binary for branch mode.

The second patch supports the annotation on stripped binary.

Jin Yao (2):
perf util: Print al_addr when symbol is not found
perf annotate: Support interactive annotation of code without symbols

looks good, but I'm getting crash when annotating unresolved kernel address:

jirka



Thanks for reporting the issue.

I guess you are trying the "0xffffffff81c00ae7", let me try to reproduce
this issue.

yes, I also checked and it did not happen before

jirka



I can reproduce it now.

perf record -e cycles:u ls
perf report --stdio

75.29% ls ld-2.27.so [.] do_lookup_x
23.64% ls ld-2.27.so [.] __GI___tunables_init
1.04% ls [unknown] [k] 0xffffffff85c01210
0.03% ls ld-2.27.so [.] _start

Looks it's caused by skid.

Thanks
Jin Yao