summaryrefslogtreecommitdiffstats
path: root/llvm/tools/bugpoint/Miscompilation.cpp
diff options
context:
space:
mode:
authorReid Spencer <rspencer@reidspencer.com>2006-11-11 19:05:02 +0000
committerReid Spencer <rspencer@reidspencer.com>2006-11-11 19:05:02 +0000
commit471bcb750edb2ab67cf82611ff9494e1e26e40b2 (patch)
tree91dcd872dc12d23d5ab4518c30a9369c596b7c95 /llvm/tools/bugpoint/Miscompilation.cpp
parent75db664f440299def2dca31f64e49921d90ca65b (diff)
downloadbcm5719-llvm-471bcb750edb2ab67cf82611ff9494e1e26e40b2.tar.gz
bcm5719-llvm-471bcb750edb2ab67cf82611ff9494e1e26e40b2.zip
Add a -disable-loop-extraction option to bugpoint.
llvm-svn: 31683
Diffstat (limited to 'llvm/tools/bugpoint/Miscompilation.cpp')
-rw-r--r--llvm/tools/bugpoint/Miscompilation.cpp11
1 files changed, 9 insertions, 2 deletions
diff --git a/llvm/tools/bugpoint/Miscompilation.cpp b/llvm/tools/bugpoint/Miscompilation.cpp
index 850fb83f848..116e3a53715 100644
--- a/llvm/tools/bugpoint/Miscompilation.cpp
+++ b/llvm/tools/bugpoint/Miscompilation.cpp
@@ -33,6 +33,11 @@ namespace llvm {
}
namespace {
+ static llvm::cl::opt<bool>
+ DisableLoopExtraction("disable-loop-extraction",
+ cl::desc("Don't extract loops when searching for miscompilations"),
+ cl::init(false));
+
class ReduceMiscompilingPasses : public ListReducer<const PassInfo*> {
BugDriver &BD;
public:
@@ -512,8 +517,10 @@ DebugAMiscompilation(BugDriver &BD,
// See if we can rip any loops out of the miscompiled functions and still
// trigger the problem.
- if (!BugpointIsInterrupted &&
- ExtractLoops(BD, TestFn, MiscompiledFunctions)) {
+
+ if (!DisableLoopExtraction)
+ if (!BugpointIsInterrupted &&
+ ExtractLoops(BD, TestFn, MiscompiledFunctions)) {
// Okay, we extracted some loops and the problem still appears. See if we
// can eliminate some of the created functions from being candidates.
OpenPOWER on IntegriCloud