llvm-symbolizer: teach it about PowerPC64 ELF function descriptors
authorJay Foad <jay.foad@gmail.com>
Fri, 7 Nov 2014 09:08:39 +0000 (09:08 +0000)
committerJay Foad <jay.foad@gmail.com>
Fri, 7 Nov 2014 09:08:39 +0000 (09:08 +0000)
commit222fcc59cbd2445e496f67de33e9717220bfc142
tree86b323c315ed3fd999e2c11485cdb2e04e6d9a1b
parent3f2ffe0423fdf58e2f07e32a27089c68011d4125
llvm-symbolizer: teach it about PowerPC64 ELF function descriptors

Summary:
Teach llvm-symbolizer about PowerPC64 ELF function descriptors. Symbols in the .opd section point to function descriptors, the first word of which is a pointer to the real function. For the purposes of symbolizing we pretend that the symbol points directly to the function.

This is enough to get decent function names in stack traces for unoptimized binaries, which fixes the sanitizer print-stack-trace test on PowerPC64 Linux.

Reviewers: kcc, willschm, samsonov

Reviewed By: samsonov

Subscribers: llvm-commits

Differential Revision: http://reviews.llvm.org/D6110

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@221514 91177308-0d34-0410-b5e6-96231b3b80d8
include/llvm/Support/DataExtractor.h
test/tools/llvm-symbolizer/Inputs/ppc64 [new file with mode: 0755]
test/tools/llvm-symbolizer/ppc64.test [new file with mode: 0644]
tools/llvm-symbolizer/LLVMSymbolize.cpp
tools/llvm-symbolizer/LLVMSymbolize.h