Skip to content

Commit 0e931f3

Browse files
Use new isNarrowingProfitable API
1 parent 5811e11 commit 0e931f3

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6067,7 +6067,7 @@ SDValue DAGCombiner::hoistLogicOpWithSameOpcodeHands(SDNode *N) {
60676067
return SDValue();
60686068
// Prevent an infinite loop if the target prefers the inverse
60696069
// transformation.
6070-
if (TLI.isNarrowingProfitable(XVT, VT))
6070+
if (TLI.isNarrowingProfitable(N, XVT, VT))
60716071
return SDValue();
60726072
SDValue Logic = DAG.getNode(LogicOpcode, DL, XVT, X, Y);
60736073
return DAG.getNode(HandOpcode, DL, VT, Logic);
@@ -15874,7 +15874,7 @@ SDValue DAGCombiner::visitTRUNCATE(SDNode *N) {
1587415874
break;
1587515875
}
1587615876

15877-
if (TLI.isNarrowingProfitable(SrcVT, VT)) {
15877+
if (TLI.isNarrowingProfitable(N, SrcVT, VT)) {
1587815878
switch (N0.getOpcode()) {
1587915879
case ISD::ADD:
1588015880
case ISD::SUB:

0 commit comments

Comments
 (0)