Skip to content

Commit ebb853f

Browse files
committed
[ConstraintElim] Remove unused checkCondition() parameters (NFC)
1 parent ce519b5 commit ebb853f

File tree

1 file changed

+5
-8
lines changed

1 file changed

+5
-8
lines changed

llvm/lib/Transforms/Scalar/ConstraintElimination.cpp

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1314,9 +1314,7 @@ static void generateReproducer(CmpInst *Cond, Module *M,
13141314

13151315
static std::optional<bool> checkCondition(CmpInst::Predicate Pred, Value *A,
13161316
Value *B, Instruction *CheckInst,
1317-
ConstraintInfo &Info, unsigned NumIn,
1318-
unsigned NumOut,
1319-
Instruction *ContextInst) {
1317+
ConstraintInfo &Info) {
13201318
LLVM_DEBUG(dbgs() << "Checking " << *CheckInst << "\n");
13211319

13221320
auto R = Info.getConstraintForSolving(Pred, A, B);
@@ -1385,9 +1383,9 @@ static bool checkAndReplaceCondition(
13851383
return true;
13861384
};
13871385

1388-
if (auto ImpliedCondition = checkCondition(
1389-
Cmp->getPredicate(), Cmp->getOperand(0), Cmp->getOperand(1), Cmp,
1390-
Info, NumIn, NumOut, ContextInst))
1386+
if (auto ImpliedCondition =
1387+
checkCondition(Cmp->getPredicate(), Cmp->getOperand(0),
1388+
Cmp->getOperand(1), Cmp, Info))
13911389
return ReplaceCmpWithConstant(Cmp, *ImpliedCondition);
13921390
return false;
13931391
}
@@ -1446,8 +1444,7 @@ static bool checkOrAndOpImpliedByOther(
14461444
// Check if the second condition can be simplified now.
14471445
if (auto ImpliedCondition =
14481446
checkCondition(CmpToCheck->getPredicate(), CmpToCheck->getOperand(0),
1449-
CmpToCheck->getOperand(1), CmpToCheck, Info, CB.NumIn,
1450-
CB.NumOut, CB.getContextInst())) {
1447+
CmpToCheck->getOperand(1), CmpToCheck, Info)) {
14511448
if (IsOr && isa<SelectInst>(JoinOp)) {
14521449
JoinOp->setOperand(
14531450
OtherOpIdx == 0 ? 2 : 0,

0 commit comments

Comments
 (0)