qemu/fpu
Chih-Min Chao 0e9030376e softfloat: add APIs to handle alternative sNaN propagation for fmax/fmin
For "fmax/fmin ft0, ft1, ft2" and if one of the inputs is sNaN,

  The original logic:
    Return NaN and set invalid flag if ft1 == sNaN || ft2 == sNan.

  The alternative path:
    Set invalid flag if ft1 == sNaN || ft2 == sNaN.
    Return NaN only if ft1 == NaN && ft2 == NaN.

The IEEE 754 spec allows both implementation and some architecture such
as riscv choose different defintions in two spec versions.
(riscv-spec-v2.2 use original version, riscv-spec-20191213 changes to
 alternative)

Signed-off-by: Chih-Min Chao <chihmin.chao@sifive.com>
Signed-off-by: Frank Chang <frank.chang@sifive.com>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Message-Id: <20211021160847.2748577-2-frank.chang@sifive.com>
Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
2021-10-29 16:55:45 +10:00
..
meson.build meson: Split out fpu/meson.build 2021-06-11 09:26:28 -07:00
softfloat-parts-addsub.c.inc softfloat: Move addsub_floats to softfloat-parts.c.inc 2021-05-16 07:13:51 -05:00
softfloat-parts.c.inc softfloat: add APIs to handle alternative sNaN propagation for fmax/fmin 2021-10-29 16:55:45 +10:00
softfloat-specialize.c.inc softfloat: Remove assertion preventing silencing of NaN in default-NaN mode 2021-09-01 11:08:17 +01:00
softfloat.c softfloat: add APIs to handle alternative sNaN propagation for fmax/fmin 2021-10-29 16:55:45 +10:00