sim: Add partial support for IEEE 754-2008
authorFaraz Shahbazker <fshahbazker@wavecomp.com>
Wed, 2 Feb 2022 10:17:24 +0000 (11:17 +0100)
committerMike Frysinger <vapier@gentoo.org>
Sat, 5 Feb 2022 00:37:26 +0000 (19:37 -0500)
commitfc3c199facd60cc2facbfeee3e541e6aa6410f52
treecad3fd3cd57d890ca4d61500778caeccb3f3e683
parentb6af5f3a74d9ed8d78e2467a895d5ae0b732f114
sim: Add partial support for IEEE 754-2008

2022-02-01  Faraz Shahbazker  <fshahbazker@wavecomp.com>

sim/common/ChangeLog:
* sim-fpu.c (sim_fpu_minmax_nan): New.
(sim_fpu_max): Add variant behaviour for IEEE 754-2008.
(sim_fpu_min): Likewise.
(sim_fpu_is_un, sim_fpu_is_or): New.
(sim_fpu_un, sim_fpu_or): New.
(sim_fpu_is_ieee754_2008, sim_fpu_is_ieee754_1985): New.
(sim_fpu_set_mode): New.
(sim_fpu_classify): New.
* sim-fpu.h (sim_fpu_minmax_nan): New declaration.
(sim_fpu_un, sim_fpu_or): New declarations.
(sim_fpu_is_un, sim_fpu_is_or): New declarations.
(sim_fpu_mode): New enum.
[sim_fpu_state](current_mode): New field.
(sim_fpu_current_mode): New define.
(sim_fpu_is_ieee754_2008): New declaration.
(sim_fpu_is_ieee754_1985): New declaration.
(sim_fpu_set_mode): New declaration.
(sim_fpu_classify): New declaration.
sim/common/sim-fpu.c
sim/common/sim-fpu.h