[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH v4 13/22] fpu/softfloat: re-factor mul
From: |
Richard Henderson |
Subject: |
Re: [Qemu-devel] [PATCH v4 13/22] fpu/softfloat: re-factor mul |
Date: |
Tue, 13 Feb 2018 07:39:39 -0800 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.6.0 |
On 02/13/2018 07:20 AM, Peter Maydell wrote:
>> +static FloatParts mul_floats(FloatParts a, FloatParts b, float_status *s)
>> +{
>> + bool sign = a.sign ^ b.sign;
>> +
>> + if (a.cls == float_class_normal && b.cls == float_class_normal) {
>> + uint64_t hi, lo;
>> + int exp = a.exp + b.exp;
>> +
>> + mul64To128(a.frac, b.frac, &hi, &lo);
>
> It seems a shame that we previously were able to use a
> 32x32->64 multiply for the float32 case, and now we have to
> do an expensive 64x64->128 multiply regardless...
To be fair, I've proposed two different solutions addressing that -- c++
templates and glibc macros -- and you like neither. Is there a third
alternative that does not involve code duplication?
r~
- [Qemu-devel] [PATCH] fpu/softfloat: use hardware sqrt if we can (EXPERIMENT!), (continued)
Re: [Qemu-devel] [PATCH v4 22/22] fpu/softfloat: re-factor sqrt, Richard Henderson, 2018/02/13
[Qemu-devel] [PATCH v4 20/22] fpu/softfloat: re-factor minmax, Alex Bennée, 2018/02/06
[Qemu-devel] [PATCH v4 19/22] fpu/softfloat: re-factor scalbn, Alex Bennée, 2018/02/06
[Qemu-devel] [PATCH v4 21/22] fpu/softfloat: re-factor compare, Alex Bennée, 2018/02/06
[Qemu-devel] [PATCH v4 11/22] fpu/softfloat: define decompose structures, Alex Bennée, 2018/02/06
[Qemu-devel] [PATCH v4 18/22] fpu/softfloat: re-factor int/uint to float, Alex Bennée, 2018/02/06
[Qemu-devel] [PATCH v4 13/22] fpu/softfloat: re-factor mul, Alex Bennée, 2018/02/06
[Qemu-devel] [PATCH v4 15/22] fpu/softfloat: re-factor muladd, Alex Bennée, 2018/02/06
[Qemu-devel] [PATCH v4 17/22] fpu/softfloat: re-factor float to int/uint, Alex Bennée, 2018/02/06
[Qemu-devel] [PATCH v4 12/22] fpu/softfloat: re-factor add/sub, Alex Bennée, 2018/02/06
Re: [Qemu-devel] [PATCH v4 00/22] re-factor softfloat and add fp16 functions, no-reply, 2018/02/07
Re: [Qemu-devel] [PATCH v4 00/22] re-factor softfloat and add fp16 functions, Peter Maydell, 2018/02/13
Re: [Qemu-devel] [PATCH v4 00/22] re-factor softfloat and add fp16 functions, Peter Maydell, 2018/02/13