[llvm] [AArch64] Split large loop dependence masks (PR #153187)

Benjamin Maxwell via llvm-commits llvm-commits at lists.llvm.org
Fri Nov 7 07:38:09 PST 2025


================
@@ -1707,7 +1719,14 @@ void DAGTypeLegalizer::SplitVecRes_LOOP_DEPENDENCE_MASK(SDNode *N, SDValue &Lo,
                        : DAG.getConstant(Offset, DL, MVT::i64);
 
   PtrA = DAG.getNode(ISD::ADD, DL, MVT::i64, PtrA, Addend);
+  EVT CmpVT = MVT::i1;
+  SDValue Cmp = DAG.getSetCC(DL, CmpVT, PtrA, PtrB, ISD::CondCode::SETUGE);
----------------
MacDue wrote:

If think there's a different unsafe case for the `raw` mask (`PtrA != PtrB` but `PtrAHi == PtrB`, i.e. `PtrA = PtrB - VL/2`). 

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


More information about the llvm-commits mailing list