Skip to content

Commit 8a7a7b5

Browse files
committed
[VPlan] Remove unneeded code connecting blocks in VPBB:splitAt (NFC).
insertBlockAfter already takes care of transferring successors. Remove unneeded code to transfer them manually.
1 parent 441b82b commit 8a7a7b5

File tree

1 file changed

+0
-8
lines changed

1 file changed

+0
-8
lines changed

llvm/lib/Transforms/Vectorize/VPlan.cpp

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -552,18 +552,10 @@ VPBasicBlock *VPBasicBlock::splitAt(iterator SplitAt) {
552552
"can only split at a position in the same block");
553553

554554
SmallVector<VPBlockBase *, 2> Succs(successors());
555-
// First, disconnect the current block from its successors.
556-
for (VPBlockBase *Succ : Succs)
557-
VPBlockUtils::disconnectBlocks(this, Succ);
558-
559555
// Create new empty block after the block to split.
560556
auto *SplitBlock = new VPBasicBlock(getName() + ".split");
561557
VPBlockUtils::insertBlockAfter(SplitBlock, this);
562558

563-
// Add successors for block to split to new block.
564-
for (VPBlockBase *Succ : Succs)
565-
VPBlockUtils::connectBlocks(SplitBlock, Succ);
566-
567559
// Finally, move the recipes starting at SplitAt to new block.
568560
for (VPRecipeBase &ToMove :
569561
make_early_inc_range(make_range(SplitAt, this->end())))

0 commit comments

Comments
 (0)