[llvm-commits] [llvm] r42812 - /llvm/trunk/lib/Transforms/Scalar/LoopUnswitch.cpp
Devang Patel
dpatel at apple.com
Tue Oct 9 14:31:37 PDT 2007
Author: dpatel
Date: Tue Oct 9 16:31:36 2007
New Revision: 42812
URL: http://llvm.org/viewvc/llvm-project?rev=42812&view=rev
Log:
Do not walk invalid iterator.
Modified:
llvm/trunk/lib/Transforms/Scalar/LoopUnswitch.cpp
Modified: llvm/trunk/lib/Transforms/Scalar/LoopUnswitch.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Transforms/Scalar/LoopUnswitch.cpp?rev=42812&r1=42811&r2=42812&view=diff
==============================================================================
--- llvm/trunk/lib/Transforms/Scalar/LoopUnswitch.cpp (original)
+++ llvm/trunk/lib/Transforms/Scalar/LoopUnswitch.cpp Tue Oct 9 16:31:36 2007
@@ -632,8 +632,8 @@
DominanceFrontier::DomSetType &DFSet = DFI->second;
for (DominanceFrontier::DomSetType::iterator DI = DFSet.begin(),
- DE = DFSet.end(); DI != DE; ++DI) {
- BasicBlock *B = *DI;
+ DE = DFSet.end(); DI != DE;) {
+ BasicBlock *B = *DI++;
if (L->contains(B))
continue;
More information about the llvm-commits
mailing list