Skip to content

Commit d945cd6

Browse files
authored
[SCEV] Improve code in isImpliedCondOperands (NFC) (#147347)
1 parent 42d079e commit d945cd6

File tree

1 file changed

+8
-15
lines changed

1 file changed

+8
-15
lines changed

llvm/lib/Analysis/ScalarEvolution.cpp

Lines changed: 8 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -12499,21 +12499,14 @@ bool ScalarEvolution::isImpliedCondOperands(CmpPredicate Pred, const SCEV *LHS,
1249912499
const SCEV *FoundLHS,
1250012500
const SCEV *FoundRHS,
1250112501
const Instruction *CtxI) {
12502-
if (isImpliedCondOperandsViaRanges(Pred, LHS, RHS, Pred, FoundLHS, FoundRHS))
12503-
return true;
12504-
12505-
if (isImpliedCondOperandsViaNoOverflow(Pred, LHS, RHS, FoundLHS, FoundRHS))
12506-
return true;
12507-
12508-
if (isImpliedCondOperandsViaShift(Pred, LHS, RHS, FoundLHS, FoundRHS))
12509-
return true;
12510-
12511-
if (isImpliedCondOperandsViaAddRecStart(Pred, LHS, RHS, FoundLHS, FoundRHS,
12512-
CtxI))
12513-
return true;
12514-
12515-
return isImpliedCondOperandsHelper(Pred, LHS, RHS,
12516-
FoundLHS, FoundRHS);
12502+
return isImpliedCondOperandsViaRanges(Pred, LHS, RHS, Pred, FoundLHS,
12503+
FoundRHS) ||
12504+
isImpliedCondOperandsViaNoOverflow(Pred, LHS, RHS, FoundLHS,
12505+
FoundRHS) ||
12506+
isImpliedCondOperandsViaShift(Pred, LHS, RHS, FoundLHS, FoundRHS) ||
12507+
isImpliedCondOperandsViaAddRecStart(Pred, LHS, RHS, FoundLHS, FoundRHS,
12508+
CtxI) ||
12509+
isImpliedCondOperandsHelper(Pred, LHS, RHS, FoundLHS, FoundRHS);
1251712510
}
1251812511

1251912512
/// Is MaybeMinMaxExpr an (U|S)(Min|Max) of Candidate and some other values?

0 commit comments

Comments
 (0)