mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-03-04 21:31:03 +00:00
If a livein is not used in the block. It's live through.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37764 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
e47c333a12
commit
292da949f6
@ -625,13 +625,15 @@ void LiveIntervals::handleLiveInRegister(MachineBasicBlock *MBB,
|
|||||||
exit:
|
exit:
|
||||||
// Live-in register might not be used at all.
|
// Live-in register might not be used at all.
|
||||||
if (end == MIIdx) {
|
if (end == MIIdx) {
|
||||||
DOUT << " dead";
|
if (isAlias) {
|
||||||
if (isAlias)
|
DOUT << " dead";
|
||||||
end = getDefIndex(MIIdx) + 1;
|
end = getDefIndex(MIIdx) + 1;
|
||||||
|
} else {
|
||||||
|
DOUT << " live through";
|
||||||
|
end = baseIndex;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
assert(start < end && "did not find end of interval?");
|
|
||||||
|
|
||||||
LiveRange LR(start, end, interval.getNextValue(~0U, 0));
|
LiveRange LR(start, end, interval.getNextValue(~0U, 0));
|
||||||
DOUT << " +" << LR << '\n';
|
DOUT << " +" << LR << '\n';
|
||||||
interval.addRange(LR);
|
interval.addRange(LR);
|
||||||
@ -662,7 +664,8 @@ void LiveIntervals::computeIntervals() {
|
|||||||
// Multiple live-ins can alias the same register.
|
// Multiple live-ins can alias the same register.
|
||||||
for (const unsigned* AS = mri_->getSubRegisters(*LI); *AS; ++AS)
|
for (const unsigned* AS = mri_->getSubRegisters(*LI); *AS; ++AS)
|
||||||
if (!hasInterval(*AS))
|
if (!hasInterval(*AS))
|
||||||
handleLiveInRegister(MBB, MIIndex, getOrCreateInterval(*AS), true);
|
handleLiveInRegister(MBB, MIIndex, getOrCreateInterval(*AS),
|
||||||
|
true);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user