This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: The perennial i386 floating-point rounding issue...
- From: dewar at gnat dot com (Robert Dewar)
- To: mrs at windriver dot com, steve at moshier dot net
- Cc: gcc at gcc dot gnu dot org, zack at codesourcery dot com
- Date: Sat, 22 Jun 2002 06:19:53 -0400 (EDT)
- Subject: Re: The perennial i386 floating-point rounding issue...
> The vast majority of the user problems like this that I have analyzed
> involve an innocent-looking program that does a compare operation
> to an extra-precise register value. In other words, the most common
> problem is not that we truncate values but that we fail to truncate
> values.
Innocent? I think not, such programs are simply incorrect if they expect
the equality operation to yield true. Now it is indeed unfortunate that
C provides no control over machine number representation (something
equivalent to the 'Machine attribute of Ada), but that's not our fault :-)
We could perhaps provide such an attribute as a GCC extension.