summaryrefslogtreecommitdiff
path: root/lib/CodeGen/LiveDebugVariables.cpp
diff options
context:
space:
mode:
authorDevang Patel <dpatel@apple.com>2011-08-04 20:42:11 +0000
committerDevang Patel <dpatel@apple.com>2011-08-04 20:42:11 +0000
commitd9f3fc7faaa7686af3e1a004d86397da9c8e0449 (patch)
tree71346adcaddcabe257852a0fb542e43b2fd1c6f5 /lib/CodeGen/LiveDebugVariables.cpp
parent1f35b178858c693261b08ab41022f92e250e08b4 (diff)
downloadllvm-d9f3fc7faaa7686af3e1a004d86397da9c8e0449.tar.gz
llvm-d9f3fc7faaa7686af3e1a004d86397da9c8e0449.tar.bz2
llvm-d9f3fc7faaa7686af3e1a004d86397da9c8e0449.tar.xz
Increment counter inside insertDebugValue().
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136915 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/LiveDebugVariables.cpp')
-rw-r--r--lib/CodeGen/LiveDebugVariables.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/CodeGen/LiveDebugVariables.cpp b/lib/CodeGen/LiveDebugVariables.cpp
index 096c47fac9..7174bddfb5 100644
--- a/lib/CodeGen/LiveDebugVariables.cpp
+++ b/lib/CodeGen/LiveDebugVariables.cpp
@@ -896,6 +896,7 @@ void UserValue::insertDebugValue(MachineBasicBlock *MBB, SlotIndex Idx,
const TargetInstrInfo &TII) {
MachineBasicBlock::iterator I = findInsertLocation(MBB, Idx, LIS);
MachineOperand &Loc = locations[LocNo];
+ ++NumInsertedDebugValues;
// Frame index locations may require a target callback.
if (Loc.isFI()) {
@@ -926,7 +927,6 @@ void UserValue::emitDebugValues(VirtRegMap *VRM, LiveIntervals &LIS,
DEBUG(dbgs() << " BB#" << MBB->getNumber() << '-' << MBBEnd);
insertDebugValue(MBB, Start, LocNo, LIS, TII);
- ++NumInsertedDebugValues;
// This interval may span multiple basic blocks.
// Insert a DBG_VALUE into each one.
while(Stop > MBBEnd) {
@@ -937,7 +937,6 @@ void UserValue::emitDebugValues(VirtRegMap *VRM, LiveIntervals &LIS,
MBBEnd = LIS.getMBBEndIdx(MBB);
DEBUG(dbgs() << " BB#" << MBB->getNumber() << '-' << MBBEnd);
insertDebugValue(MBB, Start, LocNo, LIS, TII);
- ++NumInsertedDebugValues;
}
DEBUG(dbgs() << '\n');
if (MBB == MFEnd)