Re: [Qemu-devel] [PATCH v1 15/19] fpu/softfloat: re-factor float to int/uint

2017-12-18 Thread Richard Henderson
On 12/11/2017 04:57 AM, Alex Bennée wrote: > +} > +if (p.exp < DECOMPOSED_BINARY_POINT) { > +return p.frac >> (DECOMPOSED_BINARY_POINT - p.exp); > +} else if (p.exp < 64) { > +return p.frac << (p.exp - DECOMPOSED_BINARY_POINT); > +} else { > +

[Qemu-devel] [PATCH v1 15/19] fpu/softfloat: re-factor float to int/uint

2017-12-11 Thread Alex Bennée
We share the common int64/uint64_pack_decomposed function across all the helpers and simply limit the final result depending on the final size. Signed-off-by: Alex Bennée --- fpu/softfloat.c | 1000 ++- include/fpu/softfloat.h | 13 + 2 files