wish: optimize (x > 0.) floating point comparison.
N8TM@aol.com
N8TM@aol.com
Sat Sep 26 00:52:00 GMT 1998
In a message dated 9/25/98 7:56:20 AM Pacific Daylight Time, rth@cygnus.com
writes:
> the 80-bit float format used is
> > an IEEE standard, as far as I know.
>
> Well, if you consider a standard used by exactly one machine "standard"...
>
The same standard (extended double precision) was adopted by Motorola 6888[12]
and Intel.
> > And what's wrong with having 80-bit
> > long doubles instead of 128-bit ones?
>
> No, what's wrong is that it is impossible to get intermediate results
> properly rounded without sacrificing all performance.
The 80-bit intermediate precision is sufficient in a number of documented
cases to protect the accuracy of the final standard double precision result.
My results using CELEFUNT, for example, bear this out. Using 128-bit
intermediate results will achieve this with a far greater loss of performance.
The rounding mode switch has been provided to enable 53-bit rounding mode, in
case that is desired, with a significant increase in speed of division and
sqrt(). It's true that changing the rounding mode consumes quit a bit of
time, but in practice that's more of a problem for integer truncation and for
Fortran ANINT() and NINT(), where the Fortran and IEEE standards are at odds.
How did we stray so far from the original topic of this thread?
More information about the Gcc
mailing list