long doubles?

Peter Grehan grehan at freebsd.org
Sun Jul 18 17:33:07 PDT 2004


> According to a printf of sizeof(long double), the size of a long
> double is 8 bytes, the same as a double.  However, according to
> sys/powerpc/include/float.h, LDBL_MANT_DIG == 113..  I don't know a
> lot about floating point, but I'm not sure this is possible. ;)
> 
> If long doubles are 8 bytes (and they are on MacOSX, so that's a good
> sign), then shouldn't the LDBL_* constants be the same as the DBL*
> constants from float.h?  (they are on MacOSX)

  Yeh, I'm not too sure about this. The SVR4 ABI defines long doubles
as 128 bits, and there is a GCC config knob to enable this. I'd
promised David Schultz that'd I would look at fixing this, but
haven't gotten around to it yet.

later,

Peter.



More information about the freebsd-ppc mailing list