Make this comment more closely reflect the code.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@78569 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Dan Gohman 2009-08-10 16:50:32 +00:00
parent 5743a3f201
commit eb1fedc62d

View File

@ -4061,7 +4061,7 @@ SDValue DAGCombiner::visitFMUL(SDNode *N) {
// fold (fmul X, 2.0) -> (fadd X, X)
if (N1CFP && N1CFP->isExactlyValue(+2.0))
return DAG.getNode(ISD::FADD, N->getDebugLoc(), VT, N0, N0);
// fold (fmul X, (fneg 1.0)) -> (fneg X)
// fold (fmul X, -1.0) -> (fneg X)
if (N1CFP && N1CFP->isExactlyValue(-1.0))
if (!LegalOperations || TLI.isOperationLegal(ISD::FNEG, VT))
return DAG.getNode(ISD::FNEG, N->getDebugLoc(), VT, N0);