Skip to content

Commit 73f4697

Browse files
fhahnmemfrob
authored andcommitted
[VPlan] Branches are not widened by VPWidenRecipe, assert (NFC).
1 parent 53b3855 commit 73f4697

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

llvm/lib/Transforms/Vectorize/LoopVectorize.cpp

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6930,8 +6930,8 @@ VPRecipeBuilder::tryToWidenCall(Instruction *I, VFRange &Range, VPlan &Plan) {
69306930
}
69316931

69326932
bool VPRecipeBuilder::shouldWiden(Instruction *I, VFRange &Range) const {
6933-
assert(!isa<PHINode>(I) && !isa<LoadInst>(I) && !isa<StoreInst>(I) &&
6934-
"Instruction should have been handled earlier");
6933+
assert(!isa<BranchInst>(I) && !isa<PHINode>(I) && !isa<LoadInst>(I) &&
6934+
!isa<StoreInst>(I) && "Instruction should have been handled earlier");
69356935
// Instruction should be widened, unless it is scalar after vectorization,
69366936
// scalarization is profitable or it is predicated.
69376937
auto WillScalarize = [this, I](unsigned VF) -> bool {
@@ -6961,7 +6961,6 @@ VPWidenRecipe *VPRecipeBuilder::tryToWiden(Instruction *I, VPlan &Plan) {
69616961
case Instruction::And:
69626962
case Instruction::AShr:
69636963
case Instruction::BitCast:
6964-
case Instruction::Br:
69656964
case Instruction::FAdd:
69666965
case Instruction::FCmp:
69676966
case Instruction::FDiv:

0 commit comments

Comments
 (0)