diff options
author | Bob Wilson <bob.wilson@apple.com> | 2009-05-18 21:02:18 +0000 |
---|---|---|
committer | Bob Wilson <bob.wilson@apple.com> | 2009-05-18 21:02:18 +0000 |
commit | 8ad05c4bdf2739742131adbab247e5c8ee0df857 (patch) | |
tree | 231ec365302369b2948313250eeb3c8ccaa481dc /lib/CodeGen/CodePlacementOpt.cpp | |
parent | e6abdffe06d293b68c498251b5dc9f5dba78dece (diff) |
Fix CodePlacementOpt::OptimizeIntraLoopEdges so that its return value
correctly indicates whether it changed the code.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@72038 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/CodePlacementOpt.cpp')
-rw-r--r-- | lib/CodeGen/CodePlacementOpt.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/CodeGen/CodePlacementOpt.cpp b/lib/CodeGen/CodePlacementOpt.cpp index 919ee54fb3..383098e11e 100644 --- a/lib/CodeGen/CodePlacementOpt.cpp +++ b/lib/CodeGen/CodePlacementOpt.cpp @@ -134,6 +134,7 @@ bool CodePlacementOpt::OptimizeIntraLoopEdges() { TII->RemoveBranch(*MBB); ChangedMBBs.insert(MBB); ++NumIntraElim; + Changed = true; continue; } @@ -231,6 +232,7 @@ bool CodePlacementOpt::OptimizeIntraLoopEdges() { 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()) { |