[PATCH] D36351: [lld][ELF] Add profile guided section layout
Rafael Avila de Espindola via llvm-commits
llvm-commits at lists.llvm.org
Wed Jan 31 10:33:30 PST 2018
Rui Ueyama via Phabricator <reviews at reviews.llvm.org> writes:
> ruiu added a comment.
>
> How can I test this? I wonder how to create profiling data to feed this feature.
>
To test this separately from the llvm side I am using perf to create
a complete call graph:
$ perf record -e intel_pt//u ....
# collect ifunc calls
$ perf script --no-demangle -Fip,sym,addr,flags |
grep '\(^ *jmp.*\[unknown\] =>\)' | sort -u
# collect regular calls
$ perf script --no-demangle -Fip,sym,addr,flags | grep '\(^ *call\)'
With that the attached python script creates a call graph.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: get-call-graph.py
Type: application/octet-stream
Size: 629 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20180131/4742e542/attachment.obj>
-------------- next part --------------
Cheers,
Rafael
More information about the llvm-commits
mailing list