Skip to content

Commit 44bddb8

Browse files
committed
!fixup remove dead checks.
1 parent 3dc7541 commit 44bddb8

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

llvm/lib/Transforms/Scalar/IndVarSimplify.cpp

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -808,9 +808,7 @@ static bool isLoopCounter(PHINode* Phi, Loop *L,
808808
return false;
809809

810810
const SCEV *S = SE->getSCEV(Phi);
811-
if (!match(S,
812-
m_scev_AffineAddRec(m_SCEV(), m_scev_One(), m_SpecificLoop(L))) ||
813-
cast<SCEVAddRecExpr>(S)->getLoop() != L)
811+
if (!match(S, m_scev_AffineAddRec(m_SCEV(), m_scev_One(), m_SpecificLoop(L))))
814812
return false;
815813

816814
int LatchIdx = Phi->getBasicBlockIndex(L->getLoopLatch());

0 commit comments

Comments
 (0)