From 600624a10326ad4be32be409e88b9b8580cef85d Mon Sep 17 00:00:00 2001 From: Philip Reames Date: Tue, 6 Jul 2021 08:11:11 -0700 Subject: [PATCH] [LoopVersion] Move an assert [nfc-ish] --- llvm/lib/Transforms/Utils/LoopVersioning.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/llvm/lib/Transforms/Utils/LoopVersioning.cpp b/llvm/lib/Transforms/Utils/LoopVersioning.cpp index de4fb446fdf2..8a89158788cf 100644 --- a/llvm/lib/Transforms/Utils/LoopVersioning.cpp +++ b/llvm/lib/Transforms/Utils/LoopVersioning.cpp @@ -44,11 +44,11 @@ LoopVersioning::LoopVersioning(const LoopAccessInfo &LAI, AliasChecks(Checks.begin(), Checks.end()), Preds(LAI.getPSE().getUnionPredicate()), LAI(LAI), LI(LI), DT(DT), SE(SE) { - assert(L->getUniqueExitBlock() && "No single exit block"); } void LoopVersioning::versionLoop( const SmallVectorImpl &DefsUsedOutside) { + assert(VersionedLoop->getUniqueExitBlock() && "No single exit block"); assert(VersionedLoop->isLoopSimplifyForm() && "Loop is not in loop-simplify form");