This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
Re: g77 optimization -O3 bug.
- To: Horatiu Palivan <Horatiu dot Palivan at unibas dot ch>
- Subject: Re: g77 optimization -O3 bug.
- From: Toon Moene <toon at moene dot indiv dot nluug dot nl>
- Date: Thu, 09 Mar 2000 22:27:09 +0100
- CC: egcs-bugs at egcs dot cygnus dot com
- Organization: Moene Computational Physics, Maartensdijk, The Netherlands
- References: <38C76301.8453D978@ubaclu.unibas.ch>
Horatiu Palivan wrote:
> I believe I found a "little" bug (it took me 2 weeks to localize it in a
> huge programm) for the optimization -O3 option of the g77 compiler.
> Maybe you will tell that it is not a bug (because without optimization,
> or with the option -fno-automatic it work well), but I can tell you that
> IT IS a bug. The code compiled with 4 others compilers (at maximum
> optimization) worked well (included the old good f2c !!!). The code was
> run on Linux (PPC version), I will send you the routine with problems,
> in an attached file.
I get the output you call "CORRECT" (BTW, I do not see anything wrong
with the code, so the fact that compiling with -fno-automatic gets it
"right" is just fortuitous) using gcc/g77-2.95.2 on Intel (I do not have
a PPC machine):
> * CORRECT OUTPUT:
> *K= 4 2 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
> *K= 6 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
> *K= 8 3 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
It might be wise to upgrade ...
Hope this helps,
--
Toon Moene (toon@moene.indiv.nluug.nl)
Saturnushof 14, 3738 XG Maartensdijk, The Netherlands
Phone: +31 346 214290; Fax: +31 346 214286
GNU Fortran: http://gcc.gnu.org/onlinedocs/g77_news.html