other/4894: gcc/config/float-i386.h bad define?

nzook@bga.com nzook@bga.com
Tue Nov 6 20:18:00 GMT 2001


>Number:         4894
>Category:       other
>Synopsis:       gcc/config/float-i386.h bad define?
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    unassigned
>State:          open
>Class:          wrong-code
>Submitter-Id:   net
>Arrival-Date:   Sun Nov 18 18:36:00 PST 2001
>Closed-Date:
>Last-Modified:
>Originator:     nzook@bga.com
>Release:        gcc-3.0.1
>Organization:
>Environment:
i*86
>Description:
from ${SRCDIR}/gcc/config/float-i386.h:

#if __STDC_VERSION__ >= 199901L

...

   /* Number of decimal digits to enable rounding to the given number of
      decimal digits without loss of precision.
         if FLT_RADIX == 10^n:  #mantissa * log10 (FLT_RADIX)
         else                :  ceil (1 + #mantissa * log10 (FLT_RADIX))
      where #mantissa is the number of bits in the mantissa of the widest
      supported floating-point type.
   */
# undef DECIMAL_DIG
# define DECIMAL_DIG	21

#endif	/* C99 */
>How-To-Repeat:

>Fix:
I don't care what the C standard says, NO x87 processor has ever supported more than 64 mantissas bits in an external format.  Internal fromats have usually been 66 bits.  (K7 is 68).

This redefinition is WRONG.  It should be dropped before something breaks.
>Release-Note:
>Audit-Trail:
>Unformatted:



More information about the Gcc-bugs mailing list