Re: 128 bit floating point arithmetic

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Dear Jirka,

Out of curiosity, I tested both the -m96bit-long-double and the -m128bit-long-double on my Intel box ... and both of them are 80-bit IEEE 754 numbers.  The former with 16-bits fallow (or 2 pad bytes), the latter with 48-bits fallow (or 6 pad bytes).

The -m128bit-long-double option is useful for alignment issues, NOT for improved mantissa precision nor exponent range.

Both -m96bit-long-double and -m128bit-long-double had the same test results for exponent and mantissa sizes...
float       : exp:8 mant:23+1
double      : exp:11 mant:52+1
long double : exp:15 mant:64

(The "+1" on the mantissa is if there is an implicit "hidden" most-significant bit.)

If you are curious as to the actual Intel memory layout of these different formats, I can dummy up a little ASCII art.  Let me know.

IEEE 754 terminology for (typical) C/C++ float / double / long double is single / double / extended.

More info at...
<http://babbage.cs.qc.edu/courses/cs341/IEEE-754references.html>

HTH,
--Eljay


[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux