aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/Transforms/Scalar/LoopRotation.cpp4
-rw-r--r--test/Other/2008-02-14-PassManager.ll5
2 files changed, 7 insertions, 2 deletions
diff --git a/lib/Transforms/Scalar/LoopRotation.cpp b/lib/Transforms/Scalar/LoopRotation.cpp
index 8581f9ead7..153f09563d 100644
--- a/lib/Transforms/Scalar/LoopRotation.cpp
+++ b/lib/Transforms/Scalar/LoopRotation.cpp
@@ -56,12 +56,12 @@ namespace {
// LCSSA form makes instruction renaming easier.
virtual void getAnalysisUsage(AnalysisUsage &AU) const {
+ AU.addRequiredID(LoopSimplifyID);
+ AU.addPreservedID(LoopSimplifyID);
AU.addRequiredID(LCSSAID);
AU.addPreservedID(LCSSAID);
AU.addPreserved<ScalarEvolution>();
AU.addPreserved<LoopInfo>();
- AU.addRequiredID(LoopSimplifyID);
- AU.addPreservedID(LoopSimplifyID);
AU.addPreserved<DominatorTree>();
AU.addPreserved<DominanceFrontier>();
}
diff --git a/test/Other/2008-02-14-PassManager.ll b/test/Other/2008-02-14-PassManager.ll
new file mode 100644
index 0000000000..985e1908ef
--- /dev/null
+++ b/test/Other/2008-02-14-PassManager.ll
@@ -0,0 +1,5 @@
+; RUN: llvm-as < %s | opt -loop-unroll -loop-rotate -simplifycfg -disable-output
+; PR 2028
+define i32 @test1() {
+ ret i32 0;
+}