[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH v1 16/19] fpu/softfloat: re-factor int/uint to f
From: |
Alex Bennée |
Subject: |
Re: [Qemu-devel] [PATCH v1 16/19] fpu/softfloat: re-factor int/uint to float |
Date: |
Fri, 05 Jan 2018 15:51:59 +0000 |
User-agent: |
mu4e 1.0-alpha3; emacs 26.0.90 |
Richard Henderson <address@hidden> writes:
> On 12/11/2017 04:57 AM, Alex Bennée wrote:
>> These are considerably simpler as the lower order integers can just
>> use the higher order conversion function. As the decomposed fractional
>> part is a full 64 bit rounding and inexact handling comes from the
>> pack functions.
>>
>> Signed-off-by: Alex Bennée <address@hidden>
<snip>
>>
>> static uint32_t uint32_pack_decomposed(decomposed_parts p, float_status *s)
>> {
>> uint64_t r = uint64_pack_decomposed(p, s);
>> - return r > UINT32_MAX ? UINT32_MAX : r;
>> + if (r > UINT32_MAX) {
>> + s->float_exception_flags |= float_flag_invalid;
>> + r = UINT32_MAX;
>> + }
>> + return r;
>> }
>>
>> #define F
>
> Ah, the fix for the bug in patch 15 got squashed into the wrong patch.
> ;-)
Hmm slip of the re-base... the fix has been moved.
>
>> +float16 int16_to_float16(int16_t a, float_status *status)
>> +{
>> + return int64_to_float16((int64_t) a, status);
>> +}
>
> Kill all of the redundant casts?
Ack.
>
> Otherwise, as amended in your followup,
>
> Reviewed-by: Richard Henderson <address@hidden>
>
>
> r~
--
Alex Bennée
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- Re: [Qemu-devel] [PATCH v1 16/19] fpu/softfloat: re-factor int/uint to float,
Alex Bennée <=