Lines Matching refs:Entry

185     bool VerifyPredAndCC(MachineInstr *MI, const ReduceEntry &Entry,
190 const ReduceEntry &Entry);
193 const ReduceEntry &Entry, bool LiveCPSR, bool IsSelfLoop);
198 const ReduceEntry &Entry, bool LiveCPSR,
204 const ReduceEntry &Entry, bool LiveCPSR,
332 Thumb2SizeReduce::VerifyPredAndCC(MachineInstr *MI, const ReduceEntry &Entry, in VerifyPredAndCC() argument
335 if ((is2Addr && Entry.PredCC2 == 0) || in VerifyPredAndCC()
336 (!is2Addr && Entry.PredCC1 == 0)) { in VerifyPredAndCC()
355 } else if ((is2Addr && Entry.PredCC2 == 2) || in VerifyPredAndCC()
356 (!is2Addr && Entry.PredCC1 == 2)) { in VerifyPredAndCC()
405 const ReduceEntry &Entry) { in ReduceLoadStore() argument
414 unsigned Opc = Entry.NarrowOpc1; in ReduceLoadStore()
416 uint8_t ImmLimit = Entry.Imm1Limit; in ReduceLoadStore()
418 switch (Entry.WideOpc) { in ReduceLoadStore()
424 Opc = Entry.NarrowOpc2; in ReduceLoadStore()
425 ImmLimit = Entry.Imm2Limit; in ReduceLoadStore()
466 bool IsStore = Entry.WideOpc == ARM::t2STR_POST; in ReduceLoadStore()
480 auto MIB = BuildMI(MBB, MI, dl, TII->get(Entry.NarrowOpc1)) in ReduceLoadStore()
540 Opc = Entry.NarrowOpc2; // tPOP_RET in ReduceLoadStore()
552 (Entry.WideOpc == ARM::t2LDMIA_UPD || in ReduceLoadStore()
553 Entry.WideOpc == ARM::t2STMDB_UPD)) { in ReduceLoadStore()
554 Opc = Entry.NarrowOpc2; // tPOP or tPUSH in ReduceLoadStore()
557 (Entry.WideOpc != ARM::t2LDMIA_UPD && in ReduceLoadStore()
558 Entry.WideOpc != ARM::t2STMIA_UPD)) { in ReduceLoadStore()
596 if (Entry.WideOpc == ARM::t2STMIA) in ReduceLoadStore()
633 const ReduceEntry &Entry, in ReduceSpecial() argument
640 if (ReduceTo2Addr(MBB, MI, Entry, LiveCPSR, IsSelfLoop)) in ReduceSpecial()
642 return ReduceToNarrow(MBB, MI, Entry, LiveCPSR, IsSelfLoop); in ReduceSpecial()
679 if (Entry.LowRegs1 && !VerifyLowRegs(MI)) in ReduceSpecial()
683 return ReduceLoadStore(MBB, MI, Entry); in ReduceSpecial()
694 if (ReduceTo2Addr(MBB, MI, Entry, LiveCPSR, IsSelfLoop)) in ReduceSpecial()
698 return ReduceToNarrow(MBB, MI, Entry, LiveCPSR, IsSelfLoop); in ReduceSpecial()
710 return ReduceToNarrow(MBB, MI, Entry, LiveCPSR, IsSelfLoop); in ReduceSpecial()
716 return ReduceToNarrow(MBB, MI, Entry, LiveCPSR, IsSelfLoop); in ReduceSpecial()
728 return ReduceToNarrow(MBB, MI, Entry, LiveCPSR, IsSelfLoop); in ReduceSpecial()
738 return ReduceToNarrow(MBB, MI, Entry, LiveCPSR, IsSelfLoop); in ReduceSpecial()
746 const ReduceEntry &Entry, in ReduceTo2Addr() argument
751 if (!OptimizeSize && Entry.AvoidMovs && STI->avoidMOVsShifterOperand()) in ReduceTo2Addr()
787 if (Entry.LowRegs2 && !isARMLowRegister(Reg0)) in ReduceTo2Addr()
789 if (Entry.Imm2Limit) { in ReduceTo2Addr()
791 unsigned Limit = (1 << Entry.Imm2Limit) - 1; in ReduceTo2Addr()
796 if (Entry.LowRegs2 && !isARMLowRegister(Reg2)) in ReduceTo2Addr()
801 const MCInstrDesc &NewMCID = TII->get(Entry.NarrowOpc2); in ReduceTo2Addr()
822 if (!VerifyPredAndCC(MI, Entry, true, Pred, LiveCPSR, HasCC, CCDead)) in ReduceTo2Addr()
827 if (Entry.PartFlag && NewMCID.hasOptionalDef() && HasCC && in ReduceTo2Addr()
861 const ReduceEntry &Entry, in ReduceToNarrow() argument
866 if (!OptimizeSize && Entry.AvoidMovs && STI->avoidMOVsShifterOperand()) in ReduceToNarrow()
872 if (Entry.Imm1Limit) in ReduceToNarrow()
873 Limit = (1 << Entry.Imm1Limit) - 1; in ReduceToNarrow()
884 if (Entry.LowRegs1 && !isARMLowRegister(Reg)) in ReduceToNarrow()
894 const MCInstrDesc &NewMCID = TII->get(Entry.NarrowOpc1); in ReduceToNarrow()
914 if (!VerifyPredAndCC(MI, Entry, false, Pred, LiveCPSR, HasCC, CCDead)) in ReduceToNarrow()
919 if (Entry.PartFlag && NewMCID.hasOptionalDef() && HasCC && in ReduceToNarrow()
1020 const ReduceEntry &Entry = ReduceTable[OPI->second]; in ReduceMI() local
1023 if (Entry.Special) in ReduceMI()
1024 return ReduceSpecial(MBB, MI, Entry, LiveCPSR, IsSelfLoop); in ReduceMI()
1027 if (Entry.NarrowOpc2 && in ReduceMI()
1028 ReduceTo2Addr(MBB, MI, Entry, LiveCPSR, IsSelfLoop)) in ReduceMI()
1032 if (Entry.NarrowOpc1 && in ReduceMI()
1033 ReduceToNarrow(MBB, MI, Entry, LiveCPSR, IsSelfLoop)) in ReduceMI()