Summary: This fixes failure in DebugInfo/X86/multiple-aranges.ll uncovered by D39245.
Reviewers: rafael, echristo, probinson
Reviewed By: probinson
Subscribers: probinson, llvm-commits, JDevlieghere
Tags: #debug-info
Differential Revision: https://reviews.llvm.org/D39950
llvm-svn: 326056
}
// Sort the symbols by offset within the section.
- std::sort(
+ std::stable_sort(
List.begin(), List.end(), [&](const SymbolCU &A, const SymbolCU &B) {
unsigned IA = A.Sym ? Asm->OutStreamer->GetSymbolOrder(A.Sym) : 0;
unsigned IB = B.Sym ? Asm->OutStreamer->GetSymbolOrder(B.Sym) : 0;