[llvm] [VPlan] Fix header phi VPInstruction verification. NFC (PR #151472)
David Sherwood via llvm-commits
llvm-commits at lists.llvm.org
Thu Jul 31 02:00:28 PDT 2025
================
@@ -80,8 +80,8 @@ bool VPlanVerifier::verifyPhiRecipes(const VPBasicBlock *VPBB) {
NumActiveLaneMaskPhiRecipes++;
if (IsHeaderVPBB && !isa<VPHeaderPHIRecipe, VPWidenPHIRecipe>(*RecipeI) &&
- !isa<VPInstruction>(*RecipeI) &&
- cast<VPInstruction>(RecipeI)->getOpcode() == Instruction::PHI) {
+ !(isa<VPInstruction>(*RecipeI) &&
----------------
david-arm wrote:
Looking at the definition of isPhi it seems like we're missing tests where we have a VPPredInstPHIRecipe in the header VPBB, since that seems to be the only one (besides VPInstructions) where isPhi would return true and `isa<VPHeaderPHIRecipe, VPWidenPHIRecipe>(*RecipeI)` would return false.
https://github.com/llvm/llvm-project/pull/151472
More information about the llvm-commits
mailing list