From 8f643cf8d850a236349c0132b0c4c4187aebc722 Mon Sep 17 00:00:00 2001 From: Amaury Sechet Date: Thu, 2 Feb 2017 16:07:44 +0000 Subject: [PATCH] Use N0 instead of N->getOperand(0) in DagCombiner::visitAdd. NFC git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@293903 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/CodeGen/SelectionDAG/DAGCombiner.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/CodeGen/SelectionDAG/DAGCombiner.cpp b/lib/CodeGen/SelectionDAG/DAGCombiner.cpp index 315214385bb..a0488e1b1cc 100644 --- a/lib/CodeGen/SelectionDAG/DAGCombiner.cpp +++ b/lib/CodeGen/SelectionDAG/DAGCombiner.cpp @@ -1875,7 +1875,7 @@ SDValue DAGCombiner::visitADD(SDNode *N) { // and similar xforms where the inner op is either ~0 or 0. if (NumSignBits == DestBits && isOneConstantOrOneSplatConstant(N1->getOperand(1))) - return DAG.getNode(ISD::SUB, DL, VT, N->getOperand(0), AndOp0); + return DAG.getNode(ISD::SUB, DL, VT, N0, AndOp0); } // add (sext i1), X -> sub X, (zext i1) -- 2.50.1