[PATCH] D144451: [X86] Optimize umax(X,1)
Noah Goldstein via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Feb 21 12:26:39 PST 2023
goldstein.w.n added inline comments.
================
Comment at: llvm/lib/Target/X86/X86ISelLowering.cpp:47277
+ if (CC == X86::COND_AE && isOneConstant(FalseOp) &&
+ Cond.getOpcode() == X86ISD::SUB && Cond.getOperand(0) == TrueOp &&
+ Cond.hasOneUse()) {
----------------
Can it also match `X86ISD::CMP`?
================
Comment at: llvm/lib/Target/X86/X86ISelLowering.cpp:47286
+ SDValue EFLAGS(NewSub.getNode(), 1);
+ return DAG.getNode(X86ISD::ADC, DL, DAG.getVTList(VT, MVT::i32), TrueOp,
+ DAG.getConstant(0, DL, VT), EFLAGS);
----------------
Can `ADC` valuetype by different than comparison valuetype?
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D144451/new/
https://reviews.llvm.org/D144451
More information about the llvm-commits
mailing list