target/riscv: Generate nanboxed results from fp helpers

Make sure that all results from single-precision scalar helpers
are properly nan-boxed to 64-bits.

Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Reviewed-by: LIU Zhiwei <zhiwei_liu@c-sky.com>
Message-Id: <20200724002807.441147-2-richard.henderson@linaro.org>
Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
This commit is contained in:
Richard Henderson 2020-07-23 17:28:01 -07:00 committed by Alistair Francis
parent f86d9a093d
commit 9921e3d330
2 changed files with 28 additions and 19 deletions

View file

@ -38,4 +38,9 @@ target_ulong fclass_d(uint64_t frs1);
#define SEW32 2
#define SEW64 3
static inline uint64_t nanbox_s(float32 f)
{
return f | MAKE_64BIT_MASK(32, 32);
}
#endif