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/78299] New: ICE in expand_omp_for_static_nochunk, at omp-low.c:9622


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

            Bug ID: 78299
           Summary: ICE in expand_omp_for_static_nochunk, at
                    omp-low.c:9622
           Product: gcc
           Version: 7.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: fortran
          Assignee: unassigned at gcc dot gnu.org
          Reporter: gerhard.steinmetz.fortran@t-online.de
  Target Milestone: ---

Invalid code affects version 6 and 7 in combination with
option -fcheck=all or -fcheck=bounds :


$ cat z1.f90
program p
   integer, parameter :: n = 8
   integer :: i, j
   real :: x(n), y(n)
   x = 1.0
   y = 2.0
   do j = 1, 9
      !$omp parallel workshare
      !$omp parallel default(shared)
      !$omp do
      do i = 1, n
         x(i) = x(i) * y(9)
      end do
      !$omp end do
      !$omp end parallel
      !$omp end parallel workshare
   end do
end


$ cat z2.f90
program p
   integer, parameter :: n = 8
   integer :: i, j
   real :: x(n), y(n)
   x = 1.0
   y = 2.0
   do j = 1, 9
      !$omp parallel do
      do i = 1, n
         x(i) = x(i) * y(9)
      end do
      !$omp end parallel do
   end do
end


$ gfortran-7-20161106 -fopenmp -fcheck=all z1.f90
z1.f90:12:25:

          x(i) = x(i) * y(9)
                         1
Warning: Array reference at (1) is out of bounds (9 > 8) in dimension 1
z1.f90:10:0:

       !$omp do

internal compiler error: in expand_omp_for_static_nochunk, at omp-low.c:9622
0xb1402b expand_omp_for_static_nochunk
        ../../gcc/omp-low.c:9622
0xb2ae64 expand_omp_for
        ../../gcc/omp-low.c:11596
0xb2b47a expand_omp
        ../../gcc/omp-low.c:13826
0xb2b230 expand_omp
        ../../gcc/omp-low.c:13812
0xb2b230 expand_omp
        ../../gcc/omp-low.c:13812
0xb2b230 expand_omp
        ../../gcc/omp-low.c:13812
0xb2daed execute_expand_omp
        ../../gcc/omp-low.c:14051

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