This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
Re: gcc 2.96 optimization bug on RedHat7.0/alpha
- To: Uncle George <gatgul at voicenet dot com>
- Subject: Re: gcc 2.96 optimization bug on RedHat7.0/alpha
- From: "Christopher C. Chimelis" <chris at debian dot org>
- Date: Tue, 17 Apr 2001 20:04:53 -0400 (EDT)
- cc: gcc-bugs at gcc dot gnu dot org, axp-list at redhat dot com
On Tue, 17 Apr 2001, Uncle George wrote:
> with -O2 i get the wrong answer
>
> [gat@LX gat]$ gcc -g -O2 a.c -o a
> [gat@LX gat]$ ./a
> FlooR: x = 22.16, i0=1, i1=536871996
>
>
> with -O i get a passable answer
>
> [gat@LX gat]$ gcc -g -O a.c -o a
> [gat@LX gat]$ ./a
> FlooR: x = 22.16, i0=1077291253, i1=-1030792151
>
>
> BTW what exactly is the page one uses to submit/fill in the bug report
> for gcc et al ?
This has not been fixed in upstream gcc CVS, FYI. Using your source
and the gcc 3.0 snapshot from :
chris@spawn:
~/test > gcc-3.0 -g -O2 -o uncleg uncleg.c
chris@spawn:
~/test > ./uncleg
FlooR: x = 22.16, i0=1, i1=536872108
chris@spawn:
~/test > gcc-3.0 -g -O -o uncleg uncleg.c
chris@spawn:
~/test > ./uncleg
FlooR: x = 22.16, i0=1077291253, i1=-1030792151
My local copy of a patched 2.95.4pre returns the correct results, though,
so something broke between 2.95.x and 3.0pre.
Figured that you'd want to know :-)
C