Issue 114594
Summary [mlir][arith] Arith folder for maxnumf/minnumf has wrong NaN behaviour
Labels mlir
Assignees
Reporter oowekyala
    IEEE754-2019's maximumnumf and minimumnumf have NaN as their identity element. The folder was copied from the regular maximumf and minimumf and considers that infinities are the identities.

For instance
```
%1 = arith.maxnumf %nan, %something : f32
```
should fold to `%something` but
```
%1 = arith.maxnumf %-inf, %something : f32
```
should not be folded, as if `%something` is NaN, then `%-inf` should be returned.
_______________________________________________
llvm-bugs mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs

Reply via email to