Skip to content

Commit 6699894

Browse files
committed
fix fcopysign DemandedBits
1 parent ef08d31 commit 6699894

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

llvm/lib/CodeGen/SelectionDAG/TargetLowering.cpp

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3006,10 +3006,6 @@ bool TargetLowering::SimplifyDemandedBits(
30063006
Depth + 1))
30073007
return true;
30083008

3009-
if ((Known.isNonNegative() && Known2.isNonNegative()) ||
3010-
(Known.isNegative() && Known2.isNegative()))
3011-
return TLO.CombineTo(Op, Op0);
3012-
30133009
if (Known2.isNonNegative())
30143010
return TLO.CombineTo(
30153011
Op, TLO.DAG.getNode(ISD::FABS, dl, VT, Op0, Op->getFlags()));
@@ -3034,7 +3030,7 @@ bool TargetLowering::SimplifyDemandedBits(
30343030
Depth + 1))
30353031
return true;
30363032

3037-
if (Known.isNonNegative() || Known.isNegative()) {
3033+
if (!Known.isSignUnknown()) {
30383034
Known.Zero ^= SignMask;
30393035
Known.One ^= SignMask;
30403036
}

0 commit comments

Comments
 (0)