OSDN Git Service

fpu: Handle m68k extended precision denormals properly
authorRichard Henderson <richard.henderson@linaro.org>
Mon, 21 Aug 2023 00:28:33 +0000 (17:28 -0700)
committerRichard Henderson <richard.henderson@linaro.org>
Sat, 16 Sep 2023 14:57:16 +0000 (14:57 +0000)
commit722460652b3aee89dc19df61f1f33df53a9b97c9
tree84cca92504817a5b1ccb466fa918e8cebb262090
parent00f9ef8f3dd6940001311a6230985243c3ebb996
fpu: Handle m68k extended precision denormals properly

Motorola treats denormals with explicit integer bit set as
having unbiased exponent 0, unlike Intel which treats it as
having unbiased exponent 1 (more like all other IEEE formats
that have no explicit integer bit).

Add a flag on FloatFmt to differentiate the behaviour.

Reported-by: Keith Packard <keithp@keithp.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
fpu/softfloat-parts.c.inc
fpu/softfloat.c
tests/tcg/m68k/Makefile.target
tests/tcg/m68k/denormal.c [new file with mode: 0644]