From 8572fb73fefa95f589c87b27a3dfc52c2c49ec5f Mon Sep 17 00:00:00 2001 From: Ramkumar Ramachandra Date: Thu, 30 Oct 2025 12:35:52 +0000 Subject: [PATCH] [LV] Strengthen assert: VPlan0 doesn't have WidenPHIs (NFC) VPWidenCanonicalIV and VPBlend recipes are created by VPPredicator, and VPCanonicalIVPHI and VPInstruction recipes are created by VPlanConstruction. WidenPHIs are never created. --- llvm/lib/Transforms/Vectorize/LoopVectorize.cpp | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/llvm/lib/Transforms/Vectorize/LoopVectorize.cpp b/llvm/lib/Transforms/Vectorize/LoopVectorize.cpp index f7968abbe5b6b..a8a57c8ac8239 100644 --- a/llvm/lib/Transforms/Vectorize/LoopVectorize.cpp +++ b/llvm/lib/Transforms/Vectorize/LoopVectorize.cpp @@ -8335,11 +8335,7 @@ VPlanPtr LoopVectorizationPlanner::tryToBuildVPlanWithVPRecipes( &R) || (isa(&R) && !UnderlyingValue)) continue; - - // FIXME: VPlan0, which models a copy of the original scalar loop, should - // not use VPWidenPHIRecipe to model the phis. - assert((isa(&R) || isa(&R)) && - UnderlyingValue && "unsupported recipe"); + assert(isa(&R) && UnderlyingValue && "unsupported recipe"); // TODO: Gradually replace uses of underlying instruction by analyses on // VPlan.