------- Comment #3 from kargl at gcc dot gnu dot org 2008-08-25 20:37 -------
(In reply to comment #0)
> I've got some old fortran code that has compiled with dozens of gcc versions.
> I tried recompiling with 4.3.1 and I get an internal compiler error if I try
> to
> compile with my usual compiler flags for this project.
>
> Building with -O1 works. I've also played around with removing various
> combinations of the -f flags and -malign-double, but this didn't seem to
> change
> anything.
>
> /usr/bin/gfortran -O3 -march=pentium4 -ffast-math -funroll-loops
> -fomit-frame-pointer -malign-double -fPIC -c -o fftrc.lo fftrc.f
> fftrc.f:98.8:
>
> X(2) = DCMPLX(THETA-TP,ZERO)
> 1
> Warning: Array reference at (1) is out of bounds (2 > 1) in dimension 1
While gcc should never have an ICE, what happens if you actually fix
the code?
> C
> SUBROUTINE FFTRC (A,N,X,IWK,WK)
> C SPECIFICATIONS FOR ARGUMENTS
> INTEGER N,IWK(1)
> REAL*8 A(N),WK(1)
> COMPLEX*16 X(1)
Are these really rank 1 arrays with only a single element? Try
changing these to IWK(*), WK(*), X(*).
--
kargl at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Severity|critical |normal
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37236