mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-01-14 00:32:55 +00:00
llvm-nm: Make sort more stable when symbol names are equal.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@167866 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
ba6086818d
commit
ed074e9a1b
@ -153,8 +153,8 @@ CHECKIDX: U ??_7type_info@@6B@
|
||||
CHECKIDX: 00000000 R ??_C@_0BC@IHENMCGI@b?5cannot?5be?5zero?$CB?$AA@
|
||||
CHECKIDX: w ??_Einvalid_argument@std@@UAEPAXI@Z
|
||||
CHECKIDX: w ??_Elogic_error@std@@UAEPAXI@Z
|
||||
CHECKIDX: U ??_Ginvalid_argument@std@@UAEPAXI@Z
|
||||
CHECKIDX: 00000000 T ??_Ginvalid_argument@std@@UAEPAXI@Z
|
||||
CHECKIDX: U ??_Ginvalid_argument@std@@UAEPAXI@Z
|
||||
CHECKIDX: 00000000 T ??_Glogic_error@std@@UAEPAXI@Z
|
||||
CHECKIDX: U ??_Glogic_error@std@@UAEPAXI@Z
|
||||
CHECKIDX: 00000000 D ??_R0?AVexception@std@@@8
|
||||
|
@ -150,6 +150,8 @@ namespace {
|
||||
return true;
|
||||
else if (a.Address == b.Address && a.Name < b.Name)
|
||||
return true;
|
||||
else if (a.Address == b.Address && a.Name == b.Name && a.Size < b.Size)
|
||||
return true;
|
||||
else
|
||||
return false;
|
||||
|
||||
@ -160,12 +162,21 @@ namespace {
|
||||
return true;
|
||||
else if (a.Size == b.Size && a.Name < b.Name)
|
||||
return true;
|
||||
else if (a.Size == b.Size && a.Name == b.Name && a.Address < b.Address)
|
||||
return true;
|
||||
else
|
||||
return false;
|
||||
}
|
||||
|
||||
static bool CompareSymbolName(const NMSymbol &a, const NMSymbol &b) {
|
||||
return a.Name < b.Name;
|
||||
if (a.Name < b.Name)
|
||||
return true;
|
||||
else if (a.Name == b.Name && a.Size < b.Size)
|
||||
return true;
|
||||
else if (a.Name == b.Name && a.Size == b.Size && a.Address < b.Address)
|
||||
return true;
|
||||
else
|
||||
return false;
|
||||
}
|
||||
|
||||
StringRef CurrentFilename;
|
||||
|
Loading…
x
Reference in New Issue
Block a user