[PATCH] D41037: Create reserved symbols early so they can be versioned
Rafael Ávila de Espíndola via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Dec 8 15:20:00 PST 2017
rafael created this revision.
Herald added a subscriber: mehdi_amini.
This fixes pr35570.
We were creating these symbols after parsing version scripts, so they could not be versioned.
We cannot move the version script later because we need it for lto.
One option is to move both addReservedSymbols and createSyntheticSections earlier. The disadvantage is that some sections created by createSyntheticSections replace other input sections. For example, gdb index replaces .debug_gnu_pubnames, so it wants to run after gc sections so that it can set S->Live to false.
What this patch does instead is to move just the ElfHeader creation early.
https://reviews.llvm.org/D41037
Files:
ELF/Driver.cpp
ELF/Writer.cpp
ELF/Writer.h
test/ELF/linkerscript/version-linker-symbol.s
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D41037.126218.patch
Type: text/x-patch
Size: 5087 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20171208/1ecc17b2/attachment.bin>
More information about the llvm-commits
mailing list