[Bug fortran/47574] New: internal compiler error: in build2_stat, at tree.c:3795

mlosch@uni-bremen.de gcc-bugzilla@gcc.gnu.org
Tue Feb 1 16:17:00 GMT 2011


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=47574

           Summary: internal compiler error: in build2_stat, at
                    tree.c:3795
           Product: gcc
           Version: 4.6.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: fortran
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: mlosch@uni-bremen.de


Created attachment 23200
  --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=23200
example fortran code to reproduce bug

This appears to be a problem with optimization: with -O2 routine compiles
without errors. Small changes to the code also seems to fix the problem: e.g.
changing exchWidthX to OLx in line 947
The code is part of a ocean model used in oceanography (http://mitgcm.org) and
usually compiles on unix-like platforms with a f77 compiler without problems.

command-line and output follows, fortran code is attached:
gfortran -v -save-temps -Wunused -Wuninitialized -fsecond-underscore
-fconvert=big-endian -ffixed-line-length-132 -O3 -funroll-loops -c
exch2_uv_agrid_3d_rl.f
Using built-in specs.
COLLECT_GCC=gfortran
COLLECT_LTO_WRAPPER=/usr/local/libexec/gcc/x86_64-apple-darwin10.4.0/4.6.0/lto-wrapper
Target: x86_64-apple-darwin10.4.0
Configured with: ../gcc-4.6-20101106/configure --enable-languages=c++,fortran
Thread model: posix
gcc version 4.6.0 20101106 (experimental) (GCC) 
COLLECT_GCC_OPTIONS='-mmacosx-version-min=10.6.6' '-v' '-save-temps' '-Wunused'
'-Wuninitialized' '-fsecond-underscore' '-fconvert=big-endian'
'-ffixed-line-length-132' '-O3' '-funroll-loops' '-c' '-mtune=generic'
 /usr/local/libexec/gcc/x86_64-apple-darwin10.4.0/4.6.0/f951
exch2_uv_agrid_3d_rl.f -ffixed-form -fPIC -quiet -dumpbase
exch2_uv_agrid_3d_rl.f -mmacosx-version-min=10.6.6 -mtune=generic -auxbase
exch2_uv_agrid_3d_rl -O3 -Wunused -Wuninitialized -version -fsecond-underscore
-fconvert=big-endian -ffixed-line-length-132 -funroll-loops
-fintrinsic-modules-path
/usr/local/lib/gcc/x86_64-apple-darwin10.4.0/4.6.0/finclude -o
exch2_uv_agrid_3d_rl.s
GNU Fortran (GCC) version 4.6.0 20101106 (experimental)
(x86_64-apple-darwin10.4.0)
    compiled by GNU C version 4.6.0 20101106 (experimental), GMP version 4.3.1,
MPFR version 2.4.1, MPC version 0.8.1
GGC heuristics: --param ggc-min-expand=30 --param ggc-min-heapsize=4096
GNU Fortran (GCC) version 4.6.0 20101106 (experimental)
(x86_64-apple-darwin10.4.0)
    compiled by GNU C version 4.6.0 20101106 (experimental), GMP version 4.3.1,
MPFR version 2.4.1, MPC version 0.8.1
GGC heuristics: --param ggc-min-expand=30 --param ggc-min-heapsize=4096
exch2_uv_agrid_3d_rl.f: In function ‘exch2_uv_agrid_3d_rl’:
exch2_uv_agrid_3d_rl.f:293:0: internal compiler error: in build2_stat, at
tree.c:3795
Please submit a full bug report,
with preprocessed source if appropriate.
See <http://gcc.gnu.org/bugs.html> for instructions.



More information about the Gcc-bugs mailing list