Dump live intervals in numerical order.

The old DenseMap hashed order was very confusing.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@150527 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Jakob Stoklund Olesen 2012-02-14 23:46:21 +00:00
parent 94b6e14182
commit f658af5484

View File

@ -107,10 +107,21 @@ bool LiveIntervals::runOnMachineFunction(MachineFunction &fn) {
/// print - Implement the dump method.
void LiveIntervals::print(raw_ostream &OS, const Module* ) const {
OS << "********** INTERVALS **********\n";
for (const_iterator I = begin(), E = end(); I != E; ++I) {
I->second->print(OS, tri_);
OS << "\n";
}
// Dump the physregs.
for (unsigned Reg = 1, RegE = tri_->getNumRegs(); Reg != RegE; ++Reg)
if (const LiveInterval *LI = r2iMap_.lookup(Reg)) {
LI->print(OS, tri_);
OS << '\n';
}
// Dump the virtregs.
for (unsigned Reg = 0, RegE = mri_->getNumVirtRegs(); Reg != RegE; ++Reg)
if (const LiveInterval *LI =
r2iMap_.lookup(TargetRegisterInfo::index2VirtReg(Reg))) {
LI->print(OS, tri_);
OS << '\n';
}
printInstrs(OS);
}