comp.lang.ada
 help / color / mirror / Atom feed
From: "Dmitry A. Kazakov" <mailbox@dmitry-kazakov.de>
Subject: Re: How to get high-precision floating point--MPFR
Date: Fri, 19 Oct 2012 11:45:41 +0200
Date: 2012-10-19T11:45:41+02:00	[thread overview]
Message-ID: <hik8d6t401vh$.1b453o7gjjbhp.dlg@40tude.net> (raw)
In-Reply-To: 29fc1667-46f8-40b5-aef9-bea87dc862b4@googlegroups.com

On Fri, 19 Oct 2012 01:57:19 -0700 (PDT), Jerry wrote:

> And why is the Ada type using less
> mantissa bits than the hardware?

AFAIK x86/x86-64 do not have hardware 128-bit floats (IEEE or not). See 

http://en.wikipedia.org/wiki/Quadruple-precision_floating-point_format

Which also says that gcc's long double is merely 80-bit extended precision.
That, I presume, corresponds to the GNAT's Long_Long_Float.

You could compare attributes of Long_Long_Float and
Interfaces.C.long_double, T'Machine_Mantissa (A.5.3), in particular, it
should be 64 for 80-bit extended precision.

Why GNAT uses 128 bit instead of 80 actually used bit? Maybe, because of
alignment issues.

-- 
Regards,
Dmitry A. Kazakov
http://www.dmitry-kazakov.de



  reply	other threads:[~2012-10-19  9:45 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-10-19  8:57 How to get high-precision floating point--MPFR Jerry
2012-10-19  9:45 ` Dmitry A. Kazakov [this message]
2012-10-19 10:31   ` Jerry
2012-10-19 10:47 ` Georg Bauhaus
2012-10-19 11:05   ` Jerry
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox