[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-ppc] [PATCH 03/14] target-ppc: Use float64 arg in helper_compu
From: |
David Gibson |
Subject: |
Re: [Qemu-ppc] [PATCH 03/14] target-ppc: Use float64 arg in helper_compute_fprf() |
Date: |
Fri, 6 Jan 2017 18:53:02 +1100 |
User-agent: |
Mutt/1.7.1 (2016-10-04) |
On Fri, Jan 06, 2017 at 10:27:46AM +0530, Bharata B Rao wrote:
> On Fri, Jan 06, 2017 at 09:01:17AM +1100, David Gibson wrote:
> > On Thu, Jan 05, 2017 at 04:56:08PM +0530, Nikunj A Dadhania wrote:
> > > From: Bharata B Rao <address@hidden>
> > >
> > > Use float64 argument instead of unit64_t in helper_compute_fprf()
> > > This allows code in helper_compute_fprf() to be reused later to
> > > work with float128 argument too.
> > >
> > > Signed-off-by: Bharata B Rao <address@hidden>
> > > Signed-off-by: Nikunj A Dadhania <address@hidden>
> >
> > Uh.. how can this possibly be correct, without updating the callers of
> > helper_compute_fprf()?
>
> It works currently because uint64_t argument that is passed by the
> callers is interpreted as float64 arg (via farg.d).
>
> Let me see if there is a cleaner way of doing this. Casting the
> callers with right floatXX type seems to be the easiest way.
> The requirement here is to ensure that
>
> helper_compute_fprf_float16(CPUPPCState *env, float16 arg)
> helper_compute_fprf_float32(CPUPPCState *env, float32 arg)
> helper_compute_fprf_float64(CPUPPCState *env, float64 arg)
> helper_compute_fprf_float128(CPUPPCState *env, float128 arg)
>
> get autogenerated with right floatXX argument so that it can directly
> be used with required routines (like floatXX_is_any_nan etc) w/o
> needing the CPU_DoubleU or other intermediate forms.
Ok. I think some of this explanation needs to go into the commit
message.
--
David Gibson | I'll have my music baroque, and my code
david AT gibson.dropbear.id.au | minimalist, thank you. NOT _the_ _other_
| _way_ _around_!
http://www.ozlabs.org/~dgibson
signature.asc
Description: PGP signature
- [Qemu-ppc] [PATCH 01/14] target-ppc: Add xxextractuw instruction, (continued)
- [Qemu-ppc] [PATCH 01/14] target-ppc: Add xxextractuw instruction, Nikunj A Dadhania, 2017/01/05
- [Qemu-ppc] [PATCH 09/14] target-ppc: Add xscvdpqp instruction, Nikunj A Dadhania, 2017/01/05
- [Qemu-ppc] [PATCH 08/14] target-ppc: Use correct precision for FPRF setting, Nikunj A Dadhania, 2017/01/05
- [Qemu-ppc] [PATCH 04/14] target-ppc: Replace isden by float64_is_zero_or_denormal, Nikunj A Dadhania, 2017/01/05
- [Qemu-ppc] [PATCH 07/14] target-ppc: Add xscvdphp, xscvhpdp, Nikunj A Dadhania, 2017/01/05
- [Qemu-ppc] [PATCH 10/14] target-ppc: Add xscvqpdp instruction, Nikunj A Dadhania, 2017/01/05
- [Qemu-ppc] [PATCH 03/14] target-ppc: Use float64 arg in helper_compute_fprf(), Nikunj A Dadhania, 2017/01/05
- [Qemu-ppc] [PATCH 13/14] target-ppc: Add xsxsigdp instruction, Nikunj A Dadhania, 2017/01/05
- [Qemu-ppc] [PATCH 14/14] target-ppc: Add xsxsigqp instructions, Nikunj A Dadhania, 2017/01/05
- [Qemu-ppc] [PATCH 12/14] target-ppc: Add xsxexpqp instruction, Nikunj A Dadhania, 2017/01/05
- [Qemu-ppc] [PATCH 11/14] target-ppc: Add xsxexpdp instruction, Nikunj A Dadhania, 2017/01/05
- [Qemu-ppc] [PATCH 05/14] target-ppc: Rename helper_compute_fprf to helper_compute_fprf_float64, Nikunj A Dadhania, 2017/01/05
- Re: [Qemu-ppc] [PATCH 00/14] POWER9 TCG enablements - part10, David Gibson, 2017/01/05