Live-through live interval is [mbb start, mbb end+1].
authorEvan Cheng <evan.cheng@apple.com>
Tue, 17 Jun 2008 20:13:36 +0000 (20:13 +0000)
committerEvan Cheng <evan.cheng@apple.com>
Tue, 17 Jun 2008 20:13:36 +0000 (20:13 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52431 91177308-0d34-0410-b5e6-96231b3b80d8

lib/CodeGen/LiveIntervalAnalysis.cpp

index 196109ba09d4fa66d2c936ec6c933c5087b03533..83df4d174a4cb0b0b5129fd8fa0dac2c1085a577 100644 (file)
@@ -366,7 +366,7 @@ void LiveIntervals::handleVirtualRegisterDef(MachineBasicBlock *mbb,
     for (unsigned i = 0, e = vi.AliveBlocks.size(); i != e; ++i) {
       if (vi.AliveBlocks[i]) {
         LiveRange LR(getMBBStartIdx(i),
-                     getMBBEndIdx(i),
+                     getMBBEndIdx(i)+1,  // MBB ends at -1.
                      ValNo);
         interval.addRange(LR);
         DOUT << " +" << LR;