forked from OSchip/llvm-project
[TargetLowering] In BuildSDIV, add the MULHS/SMUL_LOHI to the Created vector.
BuildUDIV was already correct. llvm-svn: 338304
This commit is contained in:
parent
a568a27dfa
commit
42d312bb83
|
@ -3494,6 +3494,9 @@ SDValue TargetLowering::BuildSDIV(SDNode *N, const APInt &Divisor,
|
|||
DAG.getConstant(magics.m, dl, VT)).getNode(), 1);
|
||||
else
|
||||
return SDValue(); // No mulhs or equvialent
|
||||
|
||||
Created.push_back(Q.getNode());
|
||||
|
||||
// If d > 0 and m < 0, add the numerator
|
||||
if (Divisor.isStrictlyPositive() && magics.m.isNegative()) {
|
||||
Q = DAG.getNode(ISD::ADD, dl, VT, Q, N->getOperand(0));
|
||||
|
|
Loading…
Reference in New Issue