1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2025-01-31 20:51:52 +01:00

[X86] Don't use the OriginalDemandedBits to calculate the DemandedMask for PMULUDQ/PMULDQ inputs.

Multiply a is complex operation so just because some bit of the output isn't used doesn't mean that bit of the input isn't used.

We might able to bound it, but it will require some more thought.

llvm-svn: 345241
This commit is contained in:
Craig Topper 2018-10-25 07:00:09 +00:00
parent 7994345558
commit 69b2652665

View File

@ -31881,7 +31881,8 @@ bool X86TargetLowering::SimplifyDemandedBitsForTargetNode(
KnownBits KnownOp;
SDValue LHS = Op.getOperand(0);
SDValue RHS = Op.getOperand(1);
APInt DemandedMask = OriginalDemandedBits & APInt::getLowBitsSet(64, 32);
// FIXME: Can we bound this better?
APInt DemandedMask = APInt::getLowBitsSet(64, 32);
if (SimplifyDemandedBits(LHS, DemandedMask, KnownOp, TLO, Depth + 1))
return true;
if (SimplifyDemandedBits(RHS, DemandedMask, KnownOp, TLO, Depth + 1))