diff options
Diffstat (limited to 'llvm/lib/CodeGen/LiveVariables.cpp')
-rw-r--r-- | llvm/lib/CodeGen/LiveVariables.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/llvm/lib/CodeGen/LiveVariables.cpp b/llvm/lib/CodeGen/LiveVariables.cpp index 40250171fe1e..34c81c92707e 100644 --- a/llvm/lib/CodeGen/LiveVariables.cpp +++ b/llvm/lib/CodeGen/LiveVariables.cpp @@ -518,7 +518,7 @@ void LiveVariables::runOnInstr(MachineInstr &MI, continue; Register MOReg = MO.getReg(); if (MO.isUse()) { - if (!(Register::isPhysicalRegister(MOReg) && MRI->isReserved(MOReg))) + if (!(MOReg.isPhysical() && MRI->isReserved(MOReg))) MO.setIsKill(false); if (MO.readsReg()) UseRegs.push_back(MOReg); @@ -526,7 +526,7 @@ void LiveVariables::runOnInstr(MachineInstr &MI, assert(MO.isDef()); // FIXME: We should not remove any dead flags. However the MIPS RDDSP // instruction needs it at the moment: http://llvm.org/PR27116. - if (Register::isPhysicalRegister(MOReg) && !MRI->isReserved(MOReg)) + if (MOReg.isPhysical() && !MRI->isReserved(MOReg)) MO.setIsDead(false); DefRegs.push_back(MOReg); } @@ -762,7 +762,7 @@ void LiveVariables::removeVirtualRegistersKilled(MachineInstr &MI) { if (MO.isReg() && MO.isKill()) { MO.setIsKill(false); Register Reg = MO.getReg(); - if (Register::isVirtualRegister(Reg)) { + if (Reg.isVirtual()) { bool removed = getVarInfo(Reg).removeKill(MI); assert(removed && "kill not in register's VarInfo?"); (void)removed; @@ -850,7 +850,7 @@ void LiveVariables::addNewBlock(MachineBasicBlock *BB, // Record all vreg defs and kills of all instructions in SuccBB. for (; BBI != BBE; ++BBI) { for (const MachineOperand &Op : BBI->operands()) { - if (Op.isReg() && Register::isVirtualRegister(Op.getReg())) { + if (Op.isReg() && Op.getReg().isVirtual()) { if (Op.isDef()) Defs.insert(Op.getReg()); else if (Op.isKill()) |