bool isHiBits64 () const { return flags & HIFLAG64; }
bool isLoBits64 () const { return flags & LOFLAG64; }
- MachineOperand& setUse () { flags |= USEFLAG; return *this; }
- MachineOperand& setDef () { flags |= DEFFLAG; return *this; }
-
// used to check if a machine register has been allocated to this operand
bool hasAllocatedReg() const {
return (regNum >= 0 &&
LV.addVirtualRegisterDead(regB, &*mbbi, prevMi);
// replace all occurences of regB with regA
- // and mark all uses and defs of regA as def&use
for (unsigned i = 1; i < mi->getNumOperands(); ++i) {
- MachineOperand& op = mi->getOperand(i);
- if (op.isRegister()) {
- if (op.getReg() == regB)
- mi->SetMachineOperandReg(i, regA);
- if (op.getReg() == regA)
- op.setDef().setUse();
- }
+ if (mi->getOperand(i).isRegister() &&
+ mi->getOperand(i).getReg() == regB)
+ mi->SetMachineOperandReg(i, regA);
}
-
DEBUG(std::cerr << "\t\tmodified original to: ";
mi->print(std::cerr, TM));
assert(mi->getOperand(0).getAllocatedRegNum() ==