[llvm] [X86] getScalarMaskingNode - if the mask is zero just return the preserved source value (PR #153575)
Simon Pilgrim via llvm-commits
llvm-commits at lists.llvm.org
Thu Aug 14 08:02:24 PDT 2025
================
@@ -26261,10 +26261,8 @@ static SDValue getScalarMaskingNode(SDValue Op, SDValue Mask,
SDValue PreservedSrc,
const X86Subtarget &Subtarget,
SelectionDAG &DAG) {
-
if (auto *MaskConst = dyn_cast<ConstantSDNode>(Mask))
- if (MaskConst->getZExtValue() & 0x1)
- return Op;
+ return (MaskConst->getZExtValue() & 0x1) ? Op : PreservedSrc;
----------------
RKSimon wrote:
You're right - we need to remove the scalar op and convert to a basic blend instead of just passing through - sorry about that
https://github.com/llvm/llvm-project/pull/153575
More information about the llvm-commits
mailing list