diff options
Diffstat (limited to 'llvm/lib/CodeGen/LiveDebugValues/InstrRefBasedImpl.cpp')
-rw-r--r-- | llvm/lib/CodeGen/LiveDebugValues/InstrRefBasedImpl.cpp | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/llvm/lib/CodeGen/LiveDebugValues/InstrRefBasedImpl.cpp b/llvm/lib/CodeGen/LiveDebugValues/InstrRefBasedImpl.cpp index 6bbd130..5d6e7f1 100644 --- a/llvm/lib/CodeGen/LiveDebugValues/InstrRefBasedImpl.cpp +++ b/llvm/lib/CodeGen/LiveDebugValues/InstrRefBasedImpl.cpp @@ -2588,8 +2588,7 @@ void InstrRefBasedLDV::placeMLocPHIs( auto CollectPHIsForLoc = [&](LocIdx L) { // Collect the set of defs. SmallPtrSet<MachineBasicBlock *, 32> DefBlocks; - for (unsigned int I = 0; I < OrderToBB.size(); ++I) { - MachineBasicBlock *MBB = OrderToBB[I]; + for (MachineBasicBlock *MBB : OrderToBB) { const auto &TransferFunc = MLocTransfer[MBB->getNumber()]; if (TransferFunc.contains(L)) DefBlocks.insert(MBB); @@ -3800,8 +3799,7 @@ bool InstrRefBasedLDV::ExtendRanges(MachineFunction &MF, // To mirror old LiveDebugValues, enumerate variables in RPOT order. Otherwise // the order is unimportant, it just has to be stable. unsigned VarAssignCount = 0; - for (unsigned int I = 0; I < OrderToBB.size(); ++I) { - auto *MBB = OrderToBB[I]; + for (MachineBasicBlock *MBB : OrderToBB) { auto *VTracker = &vlocs[MBB->getNumber()]; // Collect each variable with a DBG_VALUE in this block. for (auto &idx : VTracker->Vars) { |