[PATCH] LLD: Core: Fix file ordinals of archive members.
Rui Ueyama
ruiu at google.com
Tue Mar 3 20:19:00 PST 2015
Previously archive file members got random-ish file ordinals because
file ordinals were assigned in the same order as the resolver needs
them. In LLD, atoms in the output should be ordered in the same as
in the command line, but it was not true for archive files.
This patch (partially) fixes the issue. Now, member files get larger
file ordinals than the archive file but not larger than the next file.
So, after atoms are sorted by file ordinals, they are sorted in the
same order as in the command line.
The reason why it's partial is because the order of members in the
same archive still depends on the resolution order. This needs to be
fixed in future.
http://reviews.llvm.org/D8052
Files:
include/lld/Core/LinkingContext.h
include/lld/Core/Resolver.h
lib/Core/LinkingContext.cpp
lib/Core/Resolver.cpp
lib/ReaderWriter/ELF/AArch64/AArch64RelocationPass.cpp
lib/ReaderWriter/ELF/ARM/ARMRelocationPass.cpp
lib/ReaderWriter/ELF/Hexagon/HexagonTargetHandler.cpp
lib/ReaderWriter/ELF/Mips/MipsRelocationPass.cpp
lib/ReaderWriter/ELF/X86_64/X86_64RelocationPass.cpp
lib/ReaderWriter/PECOFF/Atoms.h
test/mach-o/library-rescan.yaml
EMAIL PREFERENCES
http://reviews.llvm.org/settings/panel/emailpreferences/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D8052.21171.patch
Type: text/x-patch
Size: 7316 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20150304/8a4d0372/attachment.bin>
More information about the llvm-commits
mailing list