From 0ee372cfe337d05e16b830221bfa142cd78b2a03 Mon Sep 17 00:00:00 2001 From: Chris Lattner Date: Sat, 13 Mar 2004 19:35:54 +0000 Subject: [PATCH] Fix the "infinite looping unless you disable adce" bug Also remove an option to disable adce :) llvm-svn: 12359 --- llvm/tools/bugpoint/CrashDebugger.cpp | 2 +- llvm/tools/bugpoint/ExtractFunction.cpp | 6 ------ 2 files changed, 1 insertion(+), 7 deletions(-) diff --git a/llvm/tools/bugpoint/CrashDebugger.cpp b/llvm/tools/bugpoint/CrashDebugger.cpp index a0b695cc21f8..04f494a0b620 100644 --- a/llvm/tools/bugpoint/CrashDebugger.cpp +++ b/llvm/tools/bugpoint/CrashDebugger.cpp @@ -330,7 +330,7 @@ static bool DebugACrash(BugDriver &BD, bool (*TestFn)(BugDriver &, Module *)) { // FIXME: This should use the list reducer to converge faster by deleting // larger chunks of instructions at a time! - unsigned Simplification = 4; + unsigned Simplification = 2; do { --Simplification; std::cout << "\n*** Attempting to reduce testcase by deleting instruc" diff --git a/llvm/tools/bugpoint/ExtractFunction.cpp b/llvm/tools/bugpoint/ExtractFunction.cpp index 9841c44c0f21..b9298d3db35f 100644 --- a/llvm/tools/bugpoint/ExtractFunction.cpp +++ b/llvm/tools/bugpoint/ExtractFunction.cpp @@ -33,9 +33,6 @@ namespace llvm { namespace { cl::opt - NoADCE("disable-adce", - cl::desc("Do not use the -adce pass to reduce testcases")); - cl::opt NoDCE ("disable-dce", cl::desc("Do not use the -dce pass to reduce testcases")); cl::opt @@ -78,9 +75,6 @@ Module *BugDriver::deleteInstructionFromProgram(const Instruction *I, // Make sure that the appropriate target data is always used... Passes.add(new TargetData("bugpoint", Result)); - if (Simplification > 2 && !NoADCE) - Passes.add(createAggressiveDCEPass()); // Remove dead code... - //Passes.add(createInstructionCombiningPass()); if (Simplification > 1 && !NoDCE) Passes.add(createDeadCodeEliminationPass()); if (Simplification && !DisableSimplifyCFG)