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/70949] New: ICE in propagate_necessity, at tree-ssa-dce.c:924


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70949

            Bug ID: 70949
           Summary: ICE in propagate_necessity, at tree-ssa-dce.c:924
           Product: gcc
           Version: 6.1.1
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: fortran
          Assignee: unassigned at gcc dot gnu.org
          Reporter: gerhard.steinmetz.fortran@t-online.de
  Target Milestone: ---

Compiling with optimization level -Og, -Os, -O1 or higher :
(affects older gfortran versions too)


$ cat z1.f90
program p
   type t1
   end type
   type t2
      type(t1), pointer :: q
   end type
   type(t1), pointer :: a
   type(t2) :: c

   allocate(a)
   c%q => a
   print *, 'a', associated(a, f(c))

contains

   function f(x) result (z)
      type(t2), intent(in) :: x
      class(t1), pointer :: z
      z => x%q
   end
end


$ gfortran-6 -O2 z1.f90
z1.f90:12:0:

    print *, 'a', associated(a, f(c))

internal compiler error: in propagate_necessity, at tree-ssa-dce.c:924

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