aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNick Lewycky <nicholas@mxc.ca>2009-05-25 06:29:56 +0000
committerNick Lewycky <nicholas@mxc.ca>2009-05-25 06:29:56 +0000
commitafd24a4d6f6c9f2a1d8634bed58a752c88e95426 (patch)
treef63c796a52eaa5a715aaa004d3b25dceb77cedf9
parent40ebc873ea3f20e0be818462bbb4a4f4f10e7dfe (diff)
downloadexternal_llvm-afd24a4d6f6c9f2a1d8634bed58a752c88e95426.zip
external_llvm-afd24a4d6f6c9f2a1d8634bed58a752c88e95426.tar.gz
external_llvm-afd24a4d6f6c9f2a1d8634bed58a752c88e95426.tar.bz2
Fix the crash debugger to actually bisect globals once it's determined that it
can't just eliminate all global initializers. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@72378 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r--tools/bugpoint/CrashDebugger.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/bugpoint/CrashDebugger.cpp b/tools/bugpoint/CrashDebugger.cpp
index f369d4e..7daf57c 100644
--- a/tools/bugpoint/CrashDebugger.cpp
+++ b/tools/bugpoint/CrashDebugger.cpp
@@ -150,7 +150,7 @@ ReduceCrashingGlobalVariables::TestGlobalVariables(
// playing with...
for (Module::global_iterator I = M->global_begin(), E = M->global_end();
I != E; ++I)
- if (I->hasInitializer()) {
+ if (I->hasInitializer() && !GVSet.count(I)) {
I->setInitializer(0);
I->setLinkage(GlobalValue::ExternalLinkage);
}