diff options
author | Chris Lattner <sabre@nondot.org> | 2006-01-11 05:10:20 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2006-01-11 05:10:20 +0000 |
commit | 88cac3d2f70d01423f56363f24e172786428b3cf (patch) | |
tree | 8d90256a0c001680ec52800a7d27bdc1310a8b71 /lib/Transforms/Scalar/GCSE.cpp | |
parent | 19ef3d5be2123d30e385f54e0e7ad46d75746920 (diff) |
Switch these to using ETForest instead of DominatorSet to compute itself.
Patch written by Daniel Berlin!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25202 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Transforms/Scalar/GCSE.cpp')
-rw-r--r-- | lib/Transforms/Scalar/GCSE.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/Transforms/Scalar/GCSE.cpp b/lib/Transforms/Scalar/GCSE.cpp index a785685b2c..3d6e624811 100644 --- a/lib/Transforms/Scalar/GCSE.cpp +++ b/lib/Transforms/Scalar/GCSE.cpp @@ -45,7 +45,7 @@ namespace { // This transformation requires dominator and immediate dominator info virtual void getAnalysisUsage(AnalysisUsage &AU) const { AU.setPreservesCFG(); - AU.addRequired<DominatorSet>(); + AU.addRequired<ETForest>(); AU.addRequired<DominatorTree>(); AU.addRequired<ValueNumbering>(); } @@ -64,7 +64,7 @@ bool GCSE::runOnFunction(Function &F) { bool Changed = false; // Get pointers to the analysis results that we will be using... - DominatorSet &DS = getAnalysis<DominatorSet>(); + ETForest &EF = getAnalysis<ETForest>(); ValueNumbering &VN = getAnalysis<ValueNumbering>(); DominatorTree &DT = getAnalysis<DominatorTree>(); @@ -141,7 +141,7 @@ bool GCSE::runOnFunction(Function &F) { if (OtherI->getParent() == BB) Dominates = BlockInsts.count(OtherI); else - Dominates = DS.dominates(OtherI->getParent(), BB); + Dominates = EF.dominates(OtherI->getParent(), BB); if (Dominates) { // Okay, we found an instruction with the same value as this one |