aboutsummaryrefslogtreecommitdiffstats
path: root/lib/Transforms/Utils/LCSSA.cpp
diff options
context:
space:
mode:
authorDan Gohman <gohman@apple.com>2010-07-16 17:58:45 +0000
committerDan Gohman <gohman@apple.com>2010-07-16 17:58:45 +0000
commit687cee6bae6255380f01ea6d5608f2d16cd62603 (patch)
tree0b0672c427eb7b797dd7539573e206c3ffeb738b /lib/Transforms/Utils/LCSSA.cpp
parentb2c1c2be5dbabbbcf75ef4868c57426a64b8db6a (diff)
downloadexternal_llvm-687cee6bae6255380f01ea6d5608f2d16cd62603.zip
external_llvm-687cee6bae6255380f01ea6d5608f2d16cd62603.tar.gz
external_llvm-687cee6bae6255380f01ea6d5608f2d16cd62603.tar.bz2
Reorder the contents of various getAnalysisUsage functions, eliminating
a redundant loopsimplify run from the default -O2 sequence. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@108539 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Transforms/Utils/LCSSA.cpp')
-rw-r--r--lib/Transforms/Utils/LCSSA.cpp18
1 files changed, 7 insertions, 11 deletions
diff --git a/lib/Transforms/Utils/LCSSA.cpp b/lib/Transforms/Utils/LCSSA.cpp
index e90c30b..5967cb9 100644
--- a/lib/Transforms/Utils/LCSSA.cpp
+++ b/lib/Transforms/Utils/LCSSA.cpp
@@ -64,22 +64,18 @@ namespace {
virtual void getAnalysisUsage(AnalysisUsage &AU) const {
AU.setPreservesCFG();
+ AU.addRequiredTransitive<DominatorTree>();
+ AU.addPreserved<DominatorTree>();
+ AU.addPreserved<DominanceFrontier>();
+ AU.addRequiredTransitive<LoopInfo>();
+ AU.addPreserved<LoopInfo>();
+
// LCSSA doesn't actually require LoopSimplify, but the PassManager
// doesn't know how to schedule LoopSimplify by itself.
AU.addRequiredID(LoopSimplifyID);
AU.addPreservedID(LoopSimplifyID);
- AU.addRequiredTransitive<LoopInfo>();
- AU.addPreserved<LoopInfo>();
- AU.addRequiredTransitive<DominatorTree>();
- AU.addPreserved<ScalarEvolution>();
- AU.addPreserved<DominatorTree>();
- // Request DominanceFrontier now, even though LCSSA does
- // not use it. This allows Pass Manager to schedule Dominance
- // Frontier early enough such that one LPPassManager can handle
- // multiple loop transformation passes.
- AU.addRequired<DominanceFrontier>();
- AU.addPreserved<DominanceFrontier>();
+ AU.addPreserved<ScalarEvolution>();
}
private:
bool ProcessInstruction(Instruction *Inst,