We shouldn't care about the debug location for a node that
we're creating, but attaching the root of the pattern should
be the best effort. (If this is not true, then we are doing
it wrong all over the SDAG).
This is no-functional-change-intended, and there are no
regression test diffs...and that's what I expected. But
there's a similar line above this diff, where those
assumptions apparently do not hold.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@348550
91177308-0d34-0410-b5e6-
96231b3b80d8
// If either operand has other uses, this transform is not an improvement.
if (!N0.hasOneUse() || !N1.hasOneUse())
return SDValue();
- SDValue Logic = DAG.getNode(LogicOpcode, SDLoc(N0), XVT, X, Y);
+ SDValue Logic = DAG.getNode(LogicOpcode, DL, XVT, X, Y);
AddToWorklist(Logic.getNode());
return DAG.getNode(HandOpcode, DL, VT, Logic, N0.getOperand(1));
}