aboutsummaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2009-07-15 04:50:47 +0000
committerChris Lattner <sabre@nondot.org>2009-07-15 04:50:47 +0000
commit98a5ca15febce8710e21e75cc7ee417f86fc6e47 (patch)
tree9c48d3fe9ff45f89432a8a03ffff44ffd617adf7 /tools
parent1ad1c1d327aa47a077ece9c0f49fc59200872b63 (diff)
downloadexternal_llvm-98a5ca15febce8710e21e75cc7ee417f86fc6e47.zip
external_llvm-98a5ca15febce8710e21e75cc7ee417f86fc6e47.tar.gz
external_llvm-98a5ca15febce8710e21e75cc7ee417f86fc6e47.tar.bz2
eliminate the Mangler::PreserveAsmNames bit, the sole client of this
can do it perfectly well itself. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@75743 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'tools')
-rw-r--r--tools/bugpoint/Miscompilation.cpp15
1 files changed, 10 insertions, 5 deletions
diff --git a/tools/bugpoint/Miscompilation.cpp b/tools/bugpoint/Miscompilation.cpp
index 4a256152..c655e71 100644
--- a/tools/bugpoint/Miscompilation.cpp
+++ b/tools/bugpoint/Miscompilation.cpp
@@ -241,12 +241,17 @@ static void DisambiguateGlobalSymbols(Module *M) {
Mangler Mang(*M);
// Agree with the CBE on symbol naming
Mang.markCharUnacceptable('.');
- Mang.setPreserveAsmNames(true);
for (Module::global_iterator I = M->global_begin(), E = M->global_end();
- I != E; ++I)
- I->setName(Mang.getMangledName(I));
- for (Module::iterator I = M->begin(), E = M->end(); I != E; ++I)
- I->setName(Mang.getMangledName(I));
+ I != E; ++I) {
+ // Don't mangle asm names.
+ if (!I->hasName() || I->getName()[0] != 1)
+ I->setName(Mang.getMangledName(I));
+ }
+ for (Module::iterator I = M->begin(), E = M->end(); I != E; ++I) {
+ // Don't mangle asm names.
+ if (!I->hasName() || I->getName()[0] != 1)
+ I->setName(Mang.getMangledName(I));
+ }
}
/// ExtractLoops - Given a reduced list of functions that still exposed the bug,