This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug fortran/17760] New: Internal compiler error for assignment to array of derived type


This is on an Athlon w/ 2GB RAM, Redhat9 (kernel 2.4.20-20.9).

$ /home/johan/gcc-test/bin/gfortran -v
Reading specs from /home/johan/gcc-test/lib/gcc/i386-redhat-linux/4.0.0/specs
Configured with: ../configure --srcdir=/home/johan/gcc
--prefix=/home/johan/gcc-test --enable-shared --enable-threads=posix
--disable-checking --with-system-zlib --enable-__cxa_atexit
--host=i386-redhat-linux --with-mpfr-dir=/home/johan/mpfr-2.0.3
--with-mpfr=/home/johan/mpfr-test --enable-languages=c,c++,f95
Thread model: posix
gcc version 4.0.0 20040930 (experimental)

$ /home/johan/gcc-test/bin/gfortran -c bug.f90
bug.f90: In function 'find_surfaces':
bug.f90:13: internal compiler error: Segmentation fault

--- begin bug.f90 ---
module seplib
  integer, parameter :: r8 = selected_real_kind(15, 307)
  type :: R_type
     real(r8), dimension(:), pointer :: coord
  end type R_type
  type :: geom_type
     type(R_type), dimension(:), pointer :: R
  end type geom_type
contains
  subroutine find_surfaces(geom)
    type(geom_type), intent(inout) :: geom
! Here's the offending line:
    geom%R(1)%coord(1) = 0.0
  end subroutine find_surfaces
end module seplib
--- end b.f90 ---

This is real code that was maximally trimmed down to still trigger the bug.

I've been tracking gfortran in the gcc main branch since the merger of tree-ssa.
Impressive progress guys! I think gfortran is very nearly there.

Thanks, Johan

-- 
           Summary: Internal compiler error for assignment to array of
                    derived type
           Product: gcc
           Version: 4.0.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: fortran
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: dr dot johan at gmail dot com
                CC: gcc-bugs at gcc dot gnu dot org


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


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]