Skip unused registers when verifying LiveIntervals.

llvm-svn: 115874
This commit is contained in:
Jakob Stoklund Olesen 2010-10-06 23:54:35 +00:00
parent c473587e28
commit 1a065e4e5b
1 changed files with 5 additions and 0 deletions

View File

@ -884,6 +884,11 @@ void MachineVerifier::verifyLiveIntervals() {
for (LiveIntervals::const_iterator LVI = LiveInts->begin(),
LVE = LiveInts->end(); LVI != LVE; ++LVI) {
const LiveInterval &LI = *LVI->second;
// Spilling and splitting may leave unused registers around. Skip them.
if (MRI->use_empty(LI.reg))
continue;
assert(LVI->first == LI.reg && "Invalid reg to interval mapping");
for (LiveInterval::const_vni_iterator I = LI.vni_begin(), E = LI.vni_end();