[llvm] e268f71 - [VPlan] Remove unneeded early continue. (NFC)
Florian Hahn via llvm-commits
llvm-commits at lists.llvm.org
Thu Apr 24 00:59:55 PDT 2025
Author: Florian Hahn
Date: 2025-04-24T08:59:30+01:00
New Revision: e268f71c5900f13207a7cd942f856f5852233d9e
URL: https://github.com/llvm/llvm-project/commit/e268f71c5900f13207a7cd942f856f5852233d9e
DIFF: https://github.com/llvm/llvm-project/commit/e268f71c5900f13207a7cd942f856f5852233d9e.diff
LOG: [VPlan] Remove unneeded early continue. (NFC)
As suggested in
https://github.com/llvm/llvm-project/pull/136455, now unreachable exit
blocks won't have any phi nodes.
Added:
Modified:
llvm/lib/Transforms/Vectorize/LoopVectorize.cpp
Removed:
################################################################################
diff --git a/llvm/lib/Transforms/Vectorize/LoopVectorize.cpp b/llvm/lib/Transforms/Vectorize/LoopVectorize.cpp
index b3b3040deed8c..5945200a4e7b7 100644
--- a/llvm/lib/Transforms/Vectorize/LoopVectorize.cpp
+++ b/llvm/lib/Transforms/Vectorize/LoopVectorize.cpp
@@ -9287,10 +9287,6 @@ static void addScalarResumePhis(VPRecipeBuilder &Builder, VPlan &Plan,
static SetVector<VPIRInstruction *> collectUsersInLatchExitBlock(VPlan &Plan) {
SetVector<VPIRInstruction *> ExitUsersToFix;
for (VPIRBasicBlock *ExitVPBB : Plan.getExitBlocks()) {
- // Nothing to do for unreachable exit blocks.
- if (ExitVPBB->getNumPredecessors() == 0)
- continue;
-
for (VPRecipeBase &R : ExitVPBB->phis()) {
auto *ExitIRI = cast<VPIRPhi>(&R);
if (ExitVPBB->getSinglePredecessor() != Plan.getMiddleBlock()) {
More information about the llvm-commits
mailing list