[PATCH] D17007: Use the plt entry as the address of some symbols
Rafael Ávila de Espíndola via llvm-commits
llvm-commits at lists.llvm.org
Mon Feb 8 16:21:55 PST 2016
rafael created this revision.
rafael added reviewers: ruiu, atanasyan, silvas.
rafael added a subscriber: llvm-commits.
rafael set the repository for this revision to rL LLVM.
This is the function equivalent of a copy relocation.
Since functions are expected to change sizes, we cannot use copy relocations. In situations where one would be needed, what is done instead is:
* Create a plt entry
* Output an undefined symbol whose addr is the plt entry.
The dynamic linker makes sure any shared library uses the plt entry as the function address.
Repository:
rL LLVM
http://reviews.llvm.org/D17007
Files:
ELF/OutputSections.cpp
ELF/Symbols.cpp
ELF/Symbols.h
ELF/Target.cpp
ELF/Target.h
ELF/Writer.cpp
test/ELF/Inputs/undef-with-plt-addr.s
test/ELF/symbol-override.s
test/ELF/undef-with-plt-addr.s
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D17007.47269.patch
Type: text/x-patch
Size: 14264 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20160209/74c137dc/attachment.bin>
More information about the llvm-commits
mailing list