mirror of
https://github.com/RPCS3/llvm.git
synced 2025-04-03 13:51:39 +00:00
Fix PR294
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12425 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
63dd4ff809
commit
6ae9eb1566
@ -172,7 +172,8 @@ void RegAllocSimple::AllocateBasicBlock(MachineBasicBlock &MBB) {
|
||||
for (int i = MI->getNumOperands() - 1; i >= 0; --i) {
|
||||
MachineOperand &op = MI->getOperand(i);
|
||||
|
||||
if (op.isRegister() && MRegisterInfo::isVirtualRegister(op.getReg())) {
|
||||
if (op.isRegister() && op.getReg() &&
|
||||
MRegisterInfo::isVirtualRegister(op.getReg())) {
|
||||
unsigned virtualReg = (unsigned) op.getReg();
|
||||
DEBUG(std::cerr << "op: " << op << "\n");
|
||||
DEBUG(std::cerr << "\t inst[" << i << "]: ";
|
||||
|
Loading…
x
Reference in New Issue
Block a user