aboutsummaryrefslogtreecommitdiff
path: root/libgomp/testsuite/libgomp.fortran/pr93553.f90
blob: 5d6f10febed7dfaa00ee365bc8db0c48ab82b8cd (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
program p
   implicit none
   integer :: x(8) = 0
   call sub(x)
end
subroutine sub(x)
   implicit none
   integer i
   integer :: x(8)
   integer :: c(8) = [(11*i, i=1,8)]
   call s
   if (any (x /= c)) stop 1
contains
   subroutine s
      integer :: i
      !$omp parallel do reduction(+:x)
      do i = 1, 8
         x(i) = c(i)
      end do
   end
end