[llvm] [DAG] ISD::matchUnaryPredicate / matchUnaryFpPredicate / matchBinaryPredicate - add DemandedElts variant (PR #183013)

Simon Pilgrim via llvm-commits llvm-commits at lists.llvm.org
Sun Mar 8 04:53:02 PDT 2026


================
@@ -6173,7 +6166,8 @@ bool SelectionDAG::isKnownNeverZero(SDValue Op, const APInt &DemandedElts,
     return !V.isZero();
   };
 
-  if (ISD::matchUnaryPredicate(Op, IsNeverZero))
+  if (ISD::matchUnaryPredicate(Op, DemandedElts, IsNeverZero,
+                               /*AllowUndefs=*/false, /*AllowTruncation=*/true))
----------------
RKSimon wrote:

Any luck triaging the test fails?

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


More information about the llvm-commits mailing list