@samitouri / QOSamiQemu / commits / da43d9b787

fpu: Inline float32_unpack_raw into callers

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org> Signed-off-by: Richard Henderson <richard.henderson@linaro.org>

Richard Henderson committed Apr 25, 2026 at 19:11 UTC da43d9b78780a5a506d811edff8988db37a3354b
1 file changed +3 -10
fpu/softfloat.c
+3 -10
@@ -646,11 +646,6 @@ static FloatParts64 unpack_raw64(const FloatFmt *fmt, uint64_t raw)
646 };
647 }
648
649 -static void QEMU_FLATTEN float32_unpack_raw(FloatParts64 *p, float32 f)
650 -{
651 - *p = unpack_raw64(&float32_params, f);
652 -}
653 -
649 static void QEMU_FLATTEN float64_unpack_raw(FloatParts64 *p, float64 f)
650 {
651 *p = unpack_raw64(&float64_params, f);
@@ -1529,7 +1524,7 @@ static bfloat16 bfloat16_round_pack_canonical(FloatParts64 *p,
1524 static void float32_unpack_canonical(FloatParts64 *p, float32 f,
1525 float_status *s)
1526 {
1532 - float32_unpack_raw(p, f);
1527 + *p = unpack_raw64(&float32_params, f);
1528 parts64_canonicalize(p, s, &float32_params);
1529 }
1530
@@ -4913,9 +4908,8 @@ float16 float16_silence_nan(float16 a, float_status *status)
4908
4909 float32 float32_silence_nan(float32 a, float_status *status)
4910 {
4916 - FloatParts64 p;
4911 + FloatParts64 p = unpack_raw64(&float32_params, a);
4912
4918 - float32_unpack_raw(&p, a);
4913 p.frac <<= float32_params.frac_shift;
4914 parts64_silence_nan(&p, status);
4915 p.frac >>= float32_params.frac_shift;
@@ -4984,9 +4978,8 @@ float16 float16_squash_input_denormal(float16 a, float_status *status)
4978 float32 float32_squash_input_denormal(float32 a, float_status *status)
4979 {
4980 if (status->flush_inputs_to_zero) {
4987 - FloatParts64 p;
4981 + FloatParts64 p = unpack_raw64(&float32_params, a);
4982
4989 - float32_unpack_raw(&p, a);
4983 if (parts_squash_denormal(p, status)) {
4984 return float32_set_sign(float32_zero, p.sign);
4985 }