Revert the last patch. We really do need SimplyCFG.
authorReid Spencer <rspencer@reidspencer.com>
Sat, 11 Dec 2004 03:03:54 +0000 (03:03 +0000)
committerReid Spencer <rspencer@reidspencer.com>
Sat, 11 Dec 2004 03:03:54 +0000 (03:03 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18787 91177308-0d34-0410-b5e6-96231b3b80d8

tools/llvm-ld/Optimize.cpp

index c676809f7711cf45951df28ebb9ed486e24a8000..5dc9424be9036b90d137b82374ffa2c2ddb95a26 100644 (file)
@@ -163,6 +163,9 @@ void Optimize(Module* M) {
     // Cleanup and simplify the code after the scalar optimizations.
     addPass(Passes, createInstructionCombiningPass());
 
+    // Delete basic blocks, which optimization passes may have killed...
+    addPass(Passes, createCFGSimplificationPass());
+
     // Now that we have optimized the program, discard unreachable functions...
     addPass(Passes, createGlobalDCEPass());
   }