From 16608b4c853ba883ac4bf5c642c4a9b4977a4fba Mon Sep 17 00:00:00 2001 From: Chris Lattner Date: Fri, 25 Apr 2003 00:52:30 +0000 Subject: [PATCH] When cleaning up the final bytecode file, make sure to run DTE as well git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5917 91177308-0d34-0410-b5e6-96231b3b80d8 --- tools/bugpoint/ExtractFunction.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tools/bugpoint/ExtractFunction.cpp b/tools/bugpoint/ExtractFunction.cpp index 2148e405f53..5451888c4f3 100644 --- a/tools/bugpoint/ExtractFunction.cpp +++ b/tools/bugpoint/ExtractFunction.cpp @@ -64,11 +64,12 @@ Module *BugDriver::deleteInstructionFromProgram(Instruction *I, /// before handing it to the user... /// Module *BugDriver::performFinalCleanups() const { + Module *M = CloneModule(Program); PassManager CleanupPasses; CleanupPasses.add(createFunctionResolvingPass()); CleanupPasses.add(createGlobalDCEPass()); + CleanupPasses.add(createDeadTypeEliminationPass()); CleanupPasses.add(createVerifierPass()); - Module *M = CloneModule(Program); CleanupPasses.run(*M); return M; } -- 2.40.0