This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Powerpc64 long double support


On Fri, Mar 05, 2004 at 06:20:24PM -0600, Steve Munroe wrote:
> +/* Powerpc64 uses the AIX long double format.
> +   
> +   Each long double is made up of two IEEE doubles.  The value of the
> +   long double is the sum of the values of the two parts.  The most
> +   significant part is required to be the value of the long double
> +   rounded to the nearest double, as specified by IEEE.  For Inf
> +   values, the least significant part is required to be one of +0.0 or
> +   -0.0.

Do you know why this is required for Inf?  If there is a reason,
then the patch I just posted to fix -0.0 is wrong..  (In any case,
the patch is incomplete, as rs6000.md extenddftf2 also needs looking
at.)

Hmm, I can see that if you represent +Inf by (+Inf + -Inf), you're
in trouble, because converting to double will result in a Nan.
Perhaps there is some sequence of operations that will result in
(+Inf + +Inf) being turned into (+Inf + -Inf)?

>  No other requirements are made; so, for example, 1.0 may be
> +   represented as (1.0, +0.0) or (1.0, -0.0), and the low part of a
> +   NaN is don't-care.  */

-- 
Alan Modra
IBM OzLabs - Linux Technology Centre


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]