Skip to content

Commit fed5ee2

Browse files
committed
Fixup: Only one call after rebase
1 parent c63af84 commit fed5ee2

File tree

1 file changed

+6
-18
lines changed

1 file changed

+6
-18
lines changed

llvm/lib/Analysis/InstructionSimplify.cpp

Lines changed: 6 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -4621,16 +4621,16 @@ static Value *simplifySelectWithEquivalence(
46214621
ArrayRef<std::pair<Value *, Value *>> Replacements, Value *TrueVal,
46224622
Value *FalseVal, const SimplifyQuery &Q, unsigned MaxRecurse) {
46234623
Value *SimplifiedFalseVal =
4624-
simplifyWithOpReplaced(FalseVal, Replacements, Q.getWithoutUndef(),
4625-
/* AllowRefinement */ false,
4626-
/* DropFlags */ nullptr, MaxRecurse);
4624+
simplifyWithOpsReplaced(FalseVal, Replacements, Q.getWithoutUndef(),
4625+
/* AllowRefinement */ false,
4626+
/* DropFlags */ nullptr, MaxRecurse);
46274627
if (!SimplifiedFalseVal)
46284628
SimplifiedFalseVal = FalseVal;
46294629

46304630
Value *SimplifiedTrueVal =
4631-
simplifyWithOpReplaced(TrueVal, Replacements, Q,
4632-
/* AllowRefinement */ true,
4633-
/* DropFlags */ nullptr, MaxRecurse);
4631+
simplifyWithOpsReplaced(TrueVal, Replacements, Q,
4632+
/* AllowRefinement */ true,
4633+
/* DropFlags */ nullptr, MaxRecurse);
46344634
if (!SimplifiedTrueVal)
46354635
SimplifiedTrueVal = TrueVal;
46364636

@@ -4744,12 +4744,6 @@ static Value *simplifySelectWithICmpCond(Value *CondVal, Value *TrueVal,
47444744
if (Value *V = simplifySelectWithEquivalence(
47454745
{{X, CmpRHS}, {Y, CmpRHS}}, TrueVal, FalseVal, Q, MaxRecurse))
47464746
return V;
4747-
if (Value *V = simplifySelectWithEquivalence({{X, CmpRHS}}, TrueVal,
4748-
FalseVal, Q, MaxRecurse))
4749-
return V;
4750-
if (Value *V = simplifySelectWithEquivalence({{Y, CmpRHS}}, TrueVal,
4751-
FalseVal, Q, MaxRecurse))
4752-
return V;
47534747
}
47544748

47554749
// select((X & Y) == -1 ? X : -1) --> -1 (commuted 2 ways)
@@ -4759,12 +4753,6 @@ static Value *simplifySelectWithICmpCond(Value *CondVal, Value *TrueVal,
47594753
if (Value *V = simplifySelectWithEquivalence(
47604754
{{X, CmpRHS}, {Y, CmpRHS}}, TrueVal, FalseVal, Q, MaxRecurse))
47614755
return V;
4762-
if (Value *V = simplifySelectWithEquivalence({{X, CmpRHS}}, TrueVal,
4763-
FalseVal, Q, MaxRecurse))
4764-
return V;
4765-
if (Value *V = simplifySelectWithEquivalence({{Y, CmpRHS}}, TrueVal,
4766-
FalseVal, Q, MaxRecurse))
4767-
return V;
47684756
}
47694757
}
47704758

0 commit comments

Comments
 (0)