Lines Matching refs:LoADDI
45 bool detectAndFoldOffset(MachineInstr &HiLUI, MachineInstr &LoADDI);
46 void foldOffset(MachineInstr &HiLUI, MachineInstr &LoADDI, MachineInstr &Tail,
81 MachineInstr *&LoADDI) { in INITIALIZE_PASS()
89 LoADDI = MRI->use_begin(HiLuiDestReg)->getParent(); in INITIALIZE_PASS()
90 if (LoADDI->getOpcode() != RISCV::ADDI || in INITIALIZE_PASS()
91 LoADDI->getOperand(2).getTargetFlags() != RISCVII::MO_LO || in INITIALIZE_PASS()
92 LoADDI->getOperand(2).getType() != MachineOperand::MO_GlobalAddress || in INITIALIZE_PASS()
93 LoADDI->getOperand(2).getOffset() != 0 || in INITIALIZE_PASS()
94 !MRI->hasOneUse(LoADDI->getOperand(0).getReg())) in INITIALIZE_PASS()
103 MachineInstr &LoADDI, in foldOffset() argument
107 LoADDI.getOperand(2).setOffset(Offset); in foldOffset()
111 LoADDI.getOperand(0).getReg()); in foldOffset()
113 << " " << HiLUI << " " << LoADDI;); in foldOffset()
180 MachineInstr &LoADDI) { in detectAndFoldOffset() argument
181 Register DestReg = LoADDI.getOperand(0).getReg(); in detectAndFoldOffset()
194 foldOffset(HiLUI, LoADDI, Tail, Offset); in detectAndFoldOffset()
209 foldOffset(HiLUI, LoADDI, Tail, Offset); in detectAndFoldOffset()
246 MachineOperand &ImmOp = LoADDI.getOperand(2); in detectAndFoldOffset()
253 DeadInstrs.insert(&LoADDI); in detectAndFoldOffset()
269 MachineInstr *LoADDI = nullptr; in runOnMachineFunction() local
270 if (!detectLuiAddiGlobal(HiLUI, LoADDI)) in runOnMachineFunction()
273 << *LoADDI->getOperand(2).getGlobal() << "\n"); in runOnMachineFunction()
275 detectAndFoldOffset(HiLUI, *LoADDI); in runOnMachineFunction()