mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-12-13 04:30:23 +00:00
Add assertion checks here to turn silent miscompiles into aborts.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85639 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
4cddfd9b6f
commit
1410b7620a
@ -50,8 +50,10 @@ void ScheduleDAG::EmitPhysRegCopy(SUnit *SU,
|
||||
break;
|
||||
}
|
||||
}
|
||||
TII->copyRegToReg(*BB, InsertPos, Reg, VRI->second,
|
||||
SU->CopyDstRC, SU->CopySrcRC);
|
||||
bool Success = TII->copyRegToReg(*BB, InsertPos, Reg, VRI->second,
|
||||
SU->CopyDstRC, SU->CopySrcRC);
|
||||
(void)Success;
|
||||
assert(Success && "copyRegToReg failed!");
|
||||
} else {
|
||||
// Copy from physical register.
|
||||
assert(I->getReg() && "Unknown physical register!");
|
||||
@ -59,8 +61,10 @@ void ScheduleDAG::EmitPhysRegCopy(SUnit *SU,
|
||||
bool isNew = VRBaseMap.insert(std::make_pair(SU, VRBase)).second;
|
||||
isNew = isNew; // Silence compiler warning.
|
||||
assert(isNew && "Node emitted out of order - early");
|
||||
TII->copyRegToReg(*BB, InsertPos, VRBase, I->getReg(),
|
||||
SU->CopyDstRC, SU->CopySrcRC);
|
||||
bool Success = TII->copyRegToReg(*BB, InsertPos, VRBase, I->getReg(),
|
||||
SU->CopyDstRC, SU->CopySrcRC);
|
||||
(void)Success;
|
||||
assert(Success && "copyRegToReg failed!");
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user