mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-12-13 20:32:21 +00:00
Debug Info: Bail out of AddMachineRegPiece() if MachineReg is not a
physical register. The call to getMinimalPhysRegClass() later on asserts on this condition. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@225852 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
57ed5ffc76
commit
bc42415f0f
@ -93,6 +93,12 @@ void DwarfExpression::AddMachineRegPiece(unsigned MachineReg,
|
||||
unsigned PieceSizeInBits,
|
||||
unsigned PieceOffsetInBits) {
|
||||
const TargetRegisterInfo *TRI = getTRI();
|
||||
if (!TRI->isPhysicalRegister(MachineReg)) {
|
||||
// FIXME: We have no reasonable way of handling errors in here.
|
||||
EmitOp(dwarf::DW_OP_nop, "nop (could not find a dwarf register number)");
|
||||
return;
|
||||
}
|
||||
|
||||
int Reg = TRI->getDwarfRegNum(MachineReg, false);
|
||||
|
||||
// If this is a valid register number, emit it.
|
||||
|
Loading…
Reference in New Issue
Block a user