Skip to content

Commit 4609f37

Browse files
committed
Simplify code
1 parent b167a5a commit 4609f37

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

llvm/lib/Transforms/Scalar/InductiveRangeCheckElimination.cpp

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -267,11 +267,7 @@ bool InductiveRangeCheck::parseRangeCheckICmp(Loop *L, ICmpInst *ICI,
267267
const SCEV *&End) {
268268
auto IsLoopInvariantAndNotUndef = [&SE, L](Value *V) {
269269
const SCEV *S = SE.getSCEV(V);
270-
271-
if (isa<SCEVCouldNotCompute>(S))
272-
return false;
273-
274-
return SE.isLoopInvariant(SE.getSCEV(V), L) && !SE.containsUndefs(S);
270+
return SE.isLoopInvariant(S, L) && !SE.containsUndefs(S);
275271
};
276272

277273
ICmpInst::Predicate Pred = ICI->getPredicate();

0 commit comments

Comments
 (0)