[NVPTX] Fix NVPTX lowering of frem when denominator is infinite.
authorBenjamin Chetioui <bchetioui@google.com>
Thu, 5 Jan 2023 08:26:13 +0000 (09:26 +0100)
committerChristian Sigg <csigg@google.com>
Thu, 5 Jan 2023 08:27:54 +0000 (09:27 +0100)
commit2c3f82b7759691f3b67f7e5940e95ac3434b1a9c
treeae2fa0f4e6ae25c243e26fa458836c338f39534f
parentccc13241208f3b6975bbef384f0a01b1b6e83e8e
[NVPTX] Fix NVPTX lowering of frem when denominator is infinite.

`frem x, {+,-}inf` must return x to match the specification of LLVM's frem.

Reviewed By: tra

Differential Revision: https://reviews.llvm.org/D140846
llvm/lib/Target/NVPTX/NVPTXInstrInfo.td
llvm/test/CodeGen/NVPTX/f16-instructions.ll
llvm/test/CodeGen/NVPTX/f16x2-instructions.ll
llvm/test/CodeGen/NVPTX/fast-math.ll