[llvm] [X86][APX] Try to replace NDD with NF instructions when optimizeCompareInstr (PR #130488)

Shengchen Kan via llvm-commits llvm-commits at lists.llvm.org
Sun Mar 9 19:05:55 PDT 2025


================
@@ -5352,10 +5352,12 @@ bool X86InstrInfo::optimizeCompareInstr(MachineInstr &CmpInstr, Register SrcReg,
   MachineInstr *MI = nullptr;
   MachineInstr *Sub = nullptr;
   MachineInstr *Movr0Inst = nullptr;
+  SmallVector<MachineInstr *, 4> NDDInsts;
   bool NoSignFlag = false;
   bool ClearsOverflowFlag = false;
   bool ShouldUpdateCC = false;
   bool IsSwapped = false;
+  bool HasCF = Subtarget.hasNF();
----------------
KanRobert wrote:

HasCF->HasNF

https://github.com/llvm/llvm-project/pull/130488


More information about the llvm-commits mailing list