[BUG][GCC] *Serious* optimization bug: Any gcc specialistsout there?
Stephan Rudlof
sr at evolgo.de
Fri Aug 4 22:55:20 UTC 2000
PS:
My xcalc calculator program gives the same (-0.74692189) result...
Stephan Rudlof wrote:
>
> David,
>
> David Chase wrote:
> >
> > At 04:31 PM 8/4/00 +0200, Stephan Rudlof wrote:
> > >the result strongly differs! (the optimized version gives the *wrong*
> > >result)
> >
> > And those results were? :-)
>
> Before 'bugfix':
> 1.000000e+20
> and
> -7.469219e-01;
> after bugfix by using compile flag -D__NO_MATH_INLINES
> in both cases
> -7.469219e-01
> .
> Reading specs from /usr/lib/gcc-lib/i486-linux/egcs-2.91.66/specs
> gcc version egcs-2.91.66 19990314/Linux (egcs-1.1.2 release)
>
> Interesting, isn't it?
>
> > I got identical behavior, in both cases printing:
> > sin(arg1): -6.452513e-01
> >
> > Gcc version:
> > gcc version egcs-2.91.57 19980901 (egcs-1.1 release)
>
> Which machine/CPU?
>
> > Checking against two Java implementations:
> > -0.6452512852657808442058
> > (they both agreed, and if rounded to 7 decimal
> > digits, they agree with the C program)
> >
> > Checking against contructive reals calculator:
> > -0.6452512852657808442058117113125230074069...
> > (agrees with Java, if rounded)
>
> To illuminate this point:
> - Does Java use a C lib to implement double arithmetics?
> - What kind of calculator have you used: A calculator emulated by your
> computer or a separate one (e.g. a Casio)?
>
> <snipped>
>
> Greetings,
>
> Stephan
>
> --
> Stephan Rudlof (sr at evolgo.de)
> "Genius doesn't work on an assembly line basis.
> You can't simply say, 'Today I will be brilliant.'"
> -- Kirk, "The Ultimate Computer", stardate 4731.3
--
Stephan Rudlof (sr at evolgo.de)
"Genius doesn't work on an assembly line basis.
You can't simply say, 'Today I will be brilliant.'"
-- Kirk, "The Ultimate Computer", stardate 4731.3
More information about the Squeak-dev
mailing list
|