================
@@ -8520,7 +8561,29 @@ 
LoopVectorizationPlanner::tryToBuildVPlanWithVPRecipes(VFRange &Range) {
   // When not folding the tail, we know that the induction increment will not
   // overflow.
   bool HasNUW = Style == TailFoldingStyle::None;
-  addCanonicalIVRecipes(*Plan, Legal->getWidestInductionType(), HasNUW, DL);
+
+  VPValue *AliasMask = nullptr;
----------------
SamTebbs33 wrote:

Currently the mask is only generated when tail predication is enabled, in which 
case it perhaps could be done with a transform since all the vector loads and 
stores will be masked anyway. However the goal is to generate the mask even 
when tail predication is disabled, to capture more cases, and so the transform 
would have to handle swapping the non-masked loads and stores to masked 
variants, which I don't think is best done with a transform since the original 
VPlan does a good job of that anyway.

I'd also argue that it's a good idea to get the masking as we want it to be 
from the beginning rather than setting up an active lane mask and building on 
top of it later on.

https://github.com/llvm/llvm-project/pull/100579
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to