[PATCH] D147866: ValueTracking: Implement computeKnownFPClass for minnum/maxnum

Joshua Cranmer via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Apr 14 12:33:47 PDT 2023


jcranmer-intel added a comment.

In D147866#4269363 <https://reviews.llvm.org/D147866#4269363>, @arsenm wrote:

> In D147866#4269348 <https://reviews.llvm.org/D147866#4269348>, @jcranmer-intel wrote:
>
>> `minnum(0.0, 0.0)` can return `-0.0`, so the handling around positive/negative zero isn't correct.
>
> How is it not correct? If either operand can be +/- 0 such is reported

If both inputs have KnownFPClass of positive zero but not negative zero, the result of the `|=` won't set the bit appropriately.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D147866/new/

https://reviews.llvm.org/D147866



More information about the llvm-commits mailing list