1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-21 12:02:58 +02:00

Revert accidental change in r237633

llvm-svn: 237635
This commit is contained in:
Matthias Braun 2015-05-18 23:18:13 +00:00
parent 6a45055979
commit bc27045946

View File

@ -2122,7 +2122,7 @@ SDValue DAGCombiner::visitSDIV(SDNode *N) {
// fold (sdiv c1, c2) -> c1/c2 // fold (sdiv c1, c2) -> c1/c2
ConstantSDNode *N0C = isConstOrConstSplat(N0); ConstantSDNode *N0C = isConstOrConstSplat(N0);
ConstantSDNode *N1C = isConstOrConstSplat(N1); ConstantSDNode *N1C = isConstOrConstSplat(N1);
if (N0C && N1C && N1C->isNullValue()) if (N0C && N1C && !N1C->isNullValue())
return DAG.FoldConstantArithmetic(ISD::SDIV, SDLoc(N), VT, N0C, N1C); return DAG.FoldConstantArithmetic(ISD::SDIV, SDLoc(N), VT, N0C, N1C);
// fold (sdiv X, 1) -> X // fold (sdiv X, 1) -> X
if (N1C && N1C->getAPIntValue() == 1LL) if (N1C && N1C->getAPIntValue() == 1LL)