[flang-commits] [flang] [flang][OpenMP] Use maxnum/minnum for lowering of max/min reduction operators (PR #89258)
Krzysztof Parzyszek via flang-commits
flang-commits at lists.llvm.org
Thu Apr 18 10:17:57 PDT 2024
kparzysz wrote:
I have a concern with making a change this early in the compilation process only to avoid a selection error in the backend. First of all, we seem to replace an IEEE-compliant operation with one that isn't. Such a replacement should only be done if the compiler is allowed to do that (via relevant FP flags). Second, this is a legal operation in MLIR, and presumably in LLVM IR. If the backend can't generate valid code for it, then it's a missing functionality in the backend. Lastly, the replacing of an IEEE-compliant operation with a similar one should be done by the backend, since it's the backend that knows (1) if the operation needs to be replaced, and (2) what to replace it with.
https://github.com/llvm/llvm-project/pull/89258
More information about the flang-commits
mailing list