[PATCH] D35473: [ELF] compareByFilePosition requires stable_sort
Shoaib Meenai via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Jul 17 12:42:59 PDT 2017
This revision was automatically updated to reflect the committed changes.
Closed by commit rL308207: [ELF] Use stable_sort for compareByFilePosition (authored by smeenai).
Changed prior to commit:
https://reviews.llvm.org/D35473?vs=106836&id=106920#toc
Repository:
rL LLVM
https://reviews.llvm.org/D35473
Files:
lld/trunk/ELF/LinkerScript.cpp
Index: lld/trunk/ELF/LinkerScript.cpp
===================================================================
--- lld/trunk/ELF/LinkerScript.cpp
+++ lld/trunk/ELF/LinkerScript.cpp
@@ -1084,7 +1084,7 @@
}
if ((Sec->Flags & SHF_LINK_ORDER)) {
- std::sort(Sections.begin(), Sections.end(), compareByFilePosition);
+ std::stable_sort(Sections.begin(), Sections.end(), compareByFilePosition);
for (int I = 0, N = Sections.size(); I < N; ++I)
*ScriptSections[I] = Sections[I];
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D35473.106920.patch
Type: text/x-patch
Size: 499 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20170717/93a59ae1/attachment.bin>
More information about the llvm-commits
mailing list