[llvm-commits] [llvm] r72038 - /llvm/trunk/lib/CodeGen/CodePlacementOpt.cpp
Bob Wilson
bob.wilson at apple.com
Mon May 18 14:03:03 PDT 2009
Author: bwilson
Date: Mon May 18 16:02:18 2009
New Revision: 72038
URL: http://llvm.org/viewvc/llvm-project?rev=72038&view=rev
Log:
Fix CodePlacementOpt::OptimizeIntraLoopEdges so that its return value
correctly indicates whether it changed the code.
Modified:
llvm/trunk/lib/CodeGen/CodePlacementOpt.cpp
Modified: llvm/trunk/lib/CodeGen/CodePlacementOpt.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/CodePlacementOpt.cpp?rev=72038&r1=72037&r2=72038&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/CodePlacementOpt.cpp (original)
+++ llvm/trunk/lib/CodeGen/CodePlacementOpt.cpp Mon May 18 16:02:18 2009
@@ -134,6 +134,7 @@
TII->RemoveBranch(*MBB);
ChangedMBBs.insert(MBB);
++NumIntraElim;
+ Changed = true;
continue;
}
@@ -231,6 +232,7 @@
TII->InsertBranch(*FtMBB, FtTBB, FtFBB, FtCond);
ChangedMBBs.insert(FtMBB);
}
+ Changed = true;
// If BB is the loop latch, we may have a new loop headr.
if (MBB == L->getLoopLatch()) {
More information about the llvm-commits
mailing list