Fix a misunderstanding about how RegMaskBlocks works. This was caught by
authorCameron Zwarich <zwarich@apple.com>
Wed, 20 Feb 2013 06:46:36 +0000 (06:46 +0000)
committerCameron Zwarich <zwarich@apple.com>
Wed, 20 Feb 2013 06:46:36 +0000 (06:46 +0000)
assertions in the register allocator when running 'make check' without
LiveVariables.

llvm-svn: 175599

llvm/include/llvm/CodeGen/LiveIntervalAnalysis.h

index c0de49e..4632368 100644 (file)
@@ -218,7 +218,7 @@ namespace llvm {
       Indexes->insertMBBInMaps(MBB);
       assert(unsigned(MBB->getNumber()) == RegMaskBlocks.size() &&
              "Blocks must be added in order.");
-      RegMaskBlocks.push_back(std::make_pair(MBB->getNumber(), 0));
+      RegMaskBlocks.push_back(std::make_pair(RegMaskSlots.size(), 0));
     }
 
     SlotIndex InsertMachineInstrInMaps(MachineInstr *MI) {