[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-ppc] [Qemu-devel] [V5 PATCH 01/22] softfloat: Fix float64_to_u
From: |
Peter Maydell |
Subject: |
Re: [Qemu-ppc] [Qemu-devel] [V5 PATCH 01/22] softfloat: Fix float64_to_uint64 |
Date: |
Mon, 6 Jan 2014 12:54:05 +0000 |
On 2 January 2014 22:21, Tom Musta <address@hidden> wrote:
> The comment preceding the float64_to_uint64 routine suggests that
> the implementation is broken. And this is, indeed, the case.
>
> This patch properly implements the conversion of a 64-bit floating
> point number to an unsigned, 64 bit integer.
>
> This contribution can be licensed under either the softfloat-2a or -2b
> license.
>
> Signed-off-by: Tom Musta <address@hidden>
Reviewed-by: Peter Maydell <address@hidden>
...but you should fix:
> --- a/fpu/softfloat.c
> +++ b/fpu/softfloat.c
> @@ -161,7 +161,6 @@ static int32 roundAndPackInt32( flag zSign, uint64_t absZ
> STATUS_PARAM)
> | exception is raised and the largest positive or negative integer is
> | returned.
>
> *----------------------------------------------------------------------------*/
> -
> static int64 roundAndPackInt64( flag zSign, uint64_t absZ0, uint64_t absZ1
> STATUS_PARAM)
this spurious blank line change...
> {
> int8 roundingMode;
>
> +
> uint64_t float64_to_uint64_round_to_zero (float64 a STATUS_PARAM)
> {
> int64_t v;
...and this one.
(I've done that for you in the copies of these patches which
I'm about to send out as the next A64 patchset, so if they
go in via my tree that's fine. Otherwise you should do
a respin or get Alex to fix it up for you as he applies them
to the ppc tree.)
thanks
-- PMM
- [Qemu-ppc] [V5 PATCH 00/22] target-ppc: PowerPC VSX Stage 3, Tom Musta, 2014/01/02
- [Qemu-ppc] [V5 PATCH 01/22] softfloat: Fix float64_to_uint64, Tom Musta, 2014/01/02
- Re: [Qemu-ppc] [Qemu-devel] [V5 PATCH 01/22] softfloat: Fix float64_to_uint64,
Peter Maydell <=
- [Qemu-ppc] [V5 PATCH 04/22] softfloat: Fix float64_to_uint32, Tom Musta, 2014/01/02
- [Qemu-ppc] [V5 PATCH 02/22] softfloat: Add float32_to_uint64(), Tom Musta, 2014/01/02
- [Qemu-ppc] [V5 PATCH 06/22] target-ppc: Add set_fprf Argument to fload_invalid_op_excp(), Tom Musta, 2014/01/02
- [Qemu-ppc] [V5 PATCH 03/22] softfloat: Fix float64_to_uint64_round_to_zero, Tom Musta, 2014/01/02
- [Qemu-ppc] [V5 PATCH 05/22] softfloat: Fix float64_to_uint32_round_to_zero, Tom Musta, 2014/01/02
- [Qemu-ppc] [V5 PATCH 08/22] target-ppc: Add VSX ISA2.06 xadd/xsub Instructions, Tom Musta, 2014/01/02
- [Qemu-ppc] [V5 PATCH 07/22] target-ppc: General Support for VSX Helpers, Tom Musta, 2014/01/02
- [Qemu-ppc] [V5 PATCH 09/22] target-ppc: Add VSX ISA2.06 xmul Instructions, Tom Musta, 2014/01/02
- [Qemu-ppc] [V5 PATCH 10/22] target-ppc: Add VSX ISA2.06 xdiv Instructions, Tom Musta, 2014/01/02