How can I get perf to find symbols in my program

后端 未结 8 1603
醉梦人生
醉梦人生 2021-01-30 09:24

When using perf report, I don\'t see any symbols for my program, instead I get output like this:

$ perf record /path/to/racket ints.rkt 10000
$ pe         


        
相关标签:
8条回答
  • 2021-01-30 10:09

    you can check the value of kptr_restrict by cat /proc/kallsyms. If the addresses of the symbols in the result are all 0x000000, you can fix it by command echo 0 > sys/kernel/kptr_restrict . After this , you may get a wanted result of the perf report

    0 讨论(0)
  • 2021-01-30 10:11

    In my case the solution was to delete the elf files which contained cached symbols from previous builds and were messing things up.

    They are in ~/.debug/ folder

    0 讨论(0)
提交回复
热议问题