================
@@ -3147,6 +3150,36 @@ Value
*InstCombinerImpl::SimplifyMultipleUseDemandedFPClass(
return Simplified;
break;
}
+ case Intrinsic::copysign: {
+ Value *Src = CI->getArgOperand(0);
+ Value *Sign = CI->getArgOperand(1);
+ KnownFPClass KnownSrc =
+ computeKnownFPClass(Src, fcAllFlags, CxtI, Depth + 1);
+
+ // Rule out some cases by magnitude, which may help prove the sign bit is
+ // one direction or the other.
+ KnownSrc.knownNot(~llvm::unknown_sign(DemandedMask));
+
+ // Cannot use nsz in the multiple use case.
----------------
dtcxzyw wrote:
Does it share the same reason with
https://github.com/llvm/llvm-project/pull/176579?
https://github.com/llvm/llvm-project/pull/176917
_______________________________________________
llvm-branch-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits