[llvm-commits] [llvm] r123278 - /llvm/trunk/lib/Transforms/Scalar/GVN.cpp
Cameron Zwarich
zwarich at apple.com
Tue Jan 11 14:14:42 PST 2011
Author: zwarich
Date: Tue Jan 11 16:14:42 2011
New Revision: 123278
URL: http://llvm.org/viewvc/llvm-project?rev=123278&view=rev
Log:
Dial back the speculative fix for PR8954 a bit, so that we only recompute dominators
once at the beginning of GVN instead of once per iteration.
Modified:
llvm/trunk/lib/Transforms/Scalar/GVN.cpp
Modified: llvm/trunk/lib/Transforms/Scalar/GVN.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Transforms/Scalar/GVN.cpp?rev=123278&r1=123277&r2=123278&view=diff
==============================================================================
--- llvm/trunk/lib/Transforms/Scalar/GVN.cpp (original)
+++ llvm/trunk/lib/Transforms/Scalar/GVN.cpp Tue Jan 11 16:14:42 2011
@@ -1754,6 +1754,9 @@
unsigned Iteration = 0;
+ // FIXME: Remove this when PR8954 is fixed.
+ DT->DT->recalculate(F);
+
while (ShouldContinue) {
DEBUG(dbgs() << "GVN iteration: " << Iteration << "\n");
ShouldContinue = iterateOnFunction(F);
@@ -2011,7 +2014,6 @@
RE = RPOT.end(); RI != RE; ++RI)
Changed |= processBlock(*RI);
#else
- DT->DT->recalculate(F);
for (df_iterator<DomTreeNode*> DI = df_begin(DT->getRootNode()),
DE = df_end(DT->getRootNode()); DI != DE; ++DI)
Changed |= processBlock(DI->getBlock());
More information about the llvm-commits
mailing list