Revert r231630 - Run LICM pass after loop unrolling pass.
As it broke llvm bootstrap.
llvm-svn: 231635
diff --git a/llvm/lib/Transforms/IPO/PassManagerBuilder.cpp b/llvm/lib/Transforms/IPO/PassManagerBuilder.cpp
index 7ff55a7..21fa34d 100644
--- a/llvm/lib/Transforms/IPO/PassManagerBuilder.cpp
+++ b/llvm/lib/Transforms/IPO/PassManagerBuilder.cpp
@@ -364,14 +364,8 @@
MPM.add(createCFGSimplificationPass());
MPM.add(createInstructionCombiningPass());
- if (!DisableUnrollLoops) {
+ if (!DisableUnrollLoops)
MPM.add(createLoopUnrollPass()); // Unroll small loops
- // Runtime unrollng will introduce runtime check in loop prologue. If the
- // unrolled loop is a inner loop, then the prologue will be inside the
- // outer loop. LICM pass can help to promote the runtime check out if the
- // checked value is loop invariant.
- MPM.add(createLICMPass());
- }
// After vectorization and unrolling, assume intrinsics may tell us more
// about pointer alignments.