[llvm] [PowerPC] Do not generate `isel` instruction if target doesn't have this instruction (PR #72845)
Qiu Chaofan via llvm-commits
llvm-commits at lists.llvm.org
Mon Nov 20 18:38:13 PST 2023
================
@@ -12701,9 +12702,10 @@ PPCTargetLowering::EmitInstrWithCustomInserter(MachineInstr &MI,
MachineFunction *F = BB->getParent();
MachineRegisterInfo &MRI = F->getRegInfo();
- if (MI.getOpcode() == PPC::SELECT_CC_I4 ||
- MI.getOpcode() == PPC::SELECT_CC_I8 || MI.getOpcode() == PPC::SELECT_I4 ||
- MI.getOpcode() == PPC::SELECT_I8) {
+ if (HasISEL &&
----------------
ecnelises wrote:
Using `Subtarget.hasISEL()` is good here if it's been used only once.
https://github.com/llvm/llvm-project/pull/72845
More information about the llvm-commits
mailing list