• Home
  • Raw
  • Download

Lines Matching refs:UseMI

78   bool xformUseMI(MachineInstr *TfrMI, MachineInstr *UseMI,
165 MachineInstr *UseMI = NodeAddr<StmtNode *>(IA).Addr->getCode(); in canRemoveAddasl() local
169 MI->getParent() != UseMI->getParent()) in canRemoveAddasl()
172 const MCInstrDesc &UseMID = UseMI->getDesc(); in canRemoveAddasl()
174 HII->getAddrMode(UseMI) != HexagonII::BaseImmOffset || in canRemoveAddasl()
175 getBaseWithLongOffset(UseMI) < 0) in canRemoveAddasl()
179 if (UseMID.mayStore() && UseMI->getOperand(2).isReg() && in canRemoveAddasl()
180 UseMI->getOperand(2).getReg() == MI->getOperand(0).getReg()) in canRemoveAddasl()
183 for (auto &Mo : UseMI->operands()) in canRemoveAddasl()
441 MachineInstr *UseMI = UseIA.Addr->getCode(); in changeAddAsl() local
442 DEBUG(dbgs() << "[MI <BB#" << UseMI->getParent()->getNumber() in changeAddAsl()
443 << ">]: " << *UseMI << "\n"); in changeAddAsl()
444 const MCInstrDesc &UseMID = UseMI->getDesc(); in changeAddAsl()
445 assert(HII->getAddrMode(UseMI) == HexagonII::BaseImmOffset); in changeAddAsl()
447 auto UsePos = MachineBasicBlock::iterator(UseMI); in changeAddAsl()
449 short NewOpCode = getBaseWithLongOffset(UseMI); in changeAddAsl()
453 unsigned OpEnd = UseMI->getNumOperands(); in changeAddAsl()
455 MachineBasicBlock *BB = UseMI->getParent(); in changeAddAsl()
457 BuildMI(*BB, InsertPt, UseMI->getDebugLoc(), HII->get(NewOpCode)); in changeAddAsl()
460 MIB.addOperand(UseMI->getOperand(0)); in changeAddAsl()
464 MIB.addGlobalAddress(GV, UseMI->getOperand(2).getImm(), in changeAddAsl()
471 MIB.addGlobalAddress(GV, UseMI->getOperand(1).getImm(), in changeAddAsl()
473 MIB.addOperand(UseMI->getOperand(2)); in changeAddAsl()
479 MIB.addOperand(UseMI->getOperand(i)); in changeAddAsl()
481 Deleted.insert(UseMI); in changeAddAsl()
487 bool HexagonOptAddrMode::xformUseMI(MachineInstr *TfrMI, MachineInstr *UseMI, in xformUseMI() argument
491 const MCInstrDesc &MID = UseMI->getDesc(); in xformUseMI()
494 Changed = changeLoad(UseMI, ImmOp, UseMOnum); in xformUseMI()
496 Changed = changeStore(UseMI, ImmOp, UseMOnum); in xformUseMI()
497 else if (UseMI->getOpcode() == Hexagon::S2_addasl_rrri) in xformUseMI()
498 Changed = changeAddAsl(UseN, UseMI, ImmOp, UseMOnum); in xformUseMI()
501 Deleted.insert(UseMI); in xformUseMI()
550 MachineInstr *UseMI = OwnerN.Addr->getCode(); in processBlock() local
551 DEBUG(dbgs() << "\t\t[MI <BB#" << UseMI->getParent()->getNumber() in processBlock()
552 << ">]: " << *UseMI << "\n"); in processBlock()
555 unsigned NumOperands = UseMI->getNumOperands(); in processBlock()
557 const MachineOperand &op = UseMI->getOperand(j); in processBlock()
563 if (InstrEvalResult[UseMI]) in processBlock()
565 Changed |= xformUseMI(MI, UseMI, UseN, UseMOnum); in processBlock()