Re: Floating point problems (accuracy).

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

 



Vincent Lefevre <vincent+gcc@xxxxxxxxxx> writes:

> But gcc has a real bug concerning the extended precision: it does
> not convert the result into double precision (when using the type
> "double") after a cast or assignment. Such a conversion is required
> by the ISO C standard (see 5.1.2.3#13, 6.3.1.5#2 and 6.3.1.8#2).
> There are no reasons not to fix it. For those who fear a performance
> loss, gcc could define a compiler switch (that could be included in
> -ffast-math).

Try the -ffloat-store option.

It's not the default because it's slows down the generated code too
much, and most people don't care.  But you raise an interesting point
about the ISO C standard.  It is possible that in strict C99 mode gcc
should enable -ffloat-store on the x86.

Ian

[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