Allow redefinition of reserved registers.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@71932 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Jakob Stoklund Olesen 2009-05-16 07:24:54 +00:00
parent 18ad4cb95d
commit d6fb97761e

View File

@ -446,7 +446,8 @@ MachineVerifier::visitMachineInstrAfter(const MachineInstr *MI)
if (TargetRegisterInfo::isPhysicalRegister(*I)) { if (TargetRegisterInfo::isPhysicalRegister(*I)) {
// We allow double defines to physical registers with live // We allow double defines to physical registers with live
// super-registers. // super-registers.
if (!allowPhysDoubleDefs && !anySuperRegisters(regsLive, *I)) { if (!allowPhysDoubleDefs && !isReserved(*I) &&
!anySuperRegisters(regsLive, *I)) {
report("Redefining a live physical register", MI); report("Redefining a live physical register", MI);
*OS << "Register " << TRI->getName(*I) *OS << "Register " << TRI->getName(*I)
<< " was defined but already live.\n"; << " was defined but already live.\n";
@ -615,7 +616,7 @@ MachineVerifier::visitMachineFunctionAfter()
for (MachineBasicBlock::const_livein_iterator I = MFI->livein_begin(), for (MachineBasicBlock::const_livein_iterator I = MFI->livein_begin(),
E = MFI->livein_end(); I != E; ++I) { E = MFI->livein_end(); I != E; ++I) {
if (TargetRegisterInfo::isPhysicalRegister(*I) && if (TargetRegisterInfo::isPhysicalRegister(*I) &&
!PrInfo.isLiveOut(*I)) { !isReserved (*I) && !PrInfo.isLiveOut(*I)) {
report("Live-in physical register is not live-out from predecessor", report("Live-in physical register is not live-out from predecessor",
MFI); MFI);
*OS << "Register " << TRI->getName(*I) *OS << "Register " << TRI->getName(*I)