Bug 21394 - Internal compiler error, possibly due to large parameter array
Summary: Internal compiler error, possibly due to large parameter array
Status: RESOLVED DUPLICATE of bug 20925
Alias: None
Product: gcc
Classification: Unclassified
Component: fortran (show other bugs)
Version: 4.0.0
: P2 normal
Target Milestone: ---
Assignee: Not yet assigned to anyone
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-05-05 07:18 UTC by Niels Langager Ellegaard
Modified: 2005-07-23 22:49 UTC (History)
1 user (show)

See Also:
Host:
Target:
Build:
Known to work:
Known to fail:
Last reconfirmed:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Niels Langager Ellegaard 2005-05-05 07:18:52 UTC
The following program causes my gfortran to throw an internal compiler 
error. The problem does not occur for N=10, so I gather that it happens 
due to a maximum limit on parameter array size. 

[niels:~]% cat test.f
      MODULE TEST

      integer ilocal

      integer,parameter :: N=50
      integer, parameter :: na = N/2
      integer, parameter :: nb = N-NA

      real*8, dimension(2),parameter :: masses=(/1.0,1.0/)

      real*8, dimension(3*n),parameter ::
     $      massvector = (/
     $      (masses(1),ilocal=1,Na),(masses(2),ilocal=1,Nb),
     $      (masses(1),ilocal=1,Na),(masses(2),ilocal=1,Nb),
     $      (masses(1),ilocal=1,Na),(masses(2),ilocal=1,Nb)
     $      /)

      END MODULE



[niels:~]% gfortran-4.0 -c test.f -o  test.o
test.f:0: internal compiler error: Possible frontend bug: array constructor not
expanded
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://gcc.gnu.org/bugs.html> for instructions.
For Debian GNU/Linux specific bug reporting instructions,
see <URL:file:///usr/share/doc/gcc-4.0/README.Bugs>.

[niels:~]% gfortran-4.0 -v -save-temps -c test.f -o  test.o
Using built-in specs.
Target: i486-linux
Configured with: ../src/configure -v --enable-languages=c,c++,java,f95,objc,ada
--prefix=/usr --libexecdir=/usr/lib --enable-shared --with-system-zlib
--enable-nls --enable-threads=posix --without-included-gettext
--program-suffix=-4.0 --enable-__cxa_atexit --enable-libstdcxx-allocator=mt
--enable-clocale=gnu --enable-libstdcxx-debug --enable-java-gc=boehm
--enable-java-awt=gtk --enable-gtk-cairo --enable-mpfr --enable-checking=release
i486-linux
Thread model: posix
gcc version 4.0.0 20050301 (prerelease) (Debian 4.0-0pre6ubuntu6)
 /usr/lib/gcc/i486-linux/4.0.0/f951 test.f -ffixed-form -quiet -dumpbase test.f
-mtune=i486 -auxbase-strip test.o -version -o test.s
GNU F95 version 4.0.0 20050301 (prerelease) (Debian 4.0-0pre6ubuntu6) (i486-linux)
        compiled by GNU C version 4.0.0 20050301 (prerelease) (Debian
4.0-0pre6ubuntu6).
GGC heuristics: --param ggc-min-expand=64 --param ggc-min-heapsize=64545
test.f:0: internal compiler error: Possible frontend bug: array constructor not
expanded
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://gcc.gnu.org/bugs.html> for instructions.
For Debian GNU/Linux specific bug reporting instructions,
see <URL:file:///usr/share/doc/gcc-4.0/README.Bugs>.
Comment 1 Andrew Pinski 2005-05-05 20:12:01 UTC

*** This bug has been marked as a duplicate of 20925 ***