diff options
author | jakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4> | 2006-10-29 10:27:39 +0000 |
---|---|---|
committer | jakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4> | 2006-10-29 10:27:39 +0000 |
commit | 6b9696405bb3994f11514e82ca9f3fbd29f48b05 (patch) | |
tree | 59c440f9db09227ba377e82b3faec95f9cd560ba /libgomp | |
parent | 26ac986ec95a37e2f8f6f8dff75e77179cf4e590 (diff) | |
download | gcc-6b9696405bb3994f11514e82ca9f3fbd29f48b05.tar.gz |
PR fortran/29629
* trans-openmp.c (gfc_trans_omp_array_reduction): Set attr.flavor
of init_val_sym and outer_sym to FL_VARIABLE.
* testsuite/libgomp.fortran/pr29629.f90: New test.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@118134 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libgomp')
-rw-r--r-- | libgomp/ChangeLog | 5 | ||||
-rw-r--r-- | libgomp/testsuite/libgomp.fortran/pr29629.f90 | 20 |
2 files changed, 25 insertions, 0 deletions
diff --git a/libgomp/ChangeLog b/libgomp/ChangeLog index d5788240f80..139b7fc5c1b 100644 --- a/libgomp/ChangeLog +++ b/libgomp/ChangeLog @@ -1,3 +1,8 @@ +2006-10-29 Jakub Jelinek <jakub@redhat.com> + + PR fortran/29629 + * testsuite/libgomp.fortran/pr29629.f90: New test. + 2006-10-24 Eric Botcazou <ebotcazou@libertysurf.fr> PR libgomp/29494 diff --git a/libgomp/testsuite/libgomp.fortran/pr29629.f90 b/libgomp/testsuite/libgomp.fortran/pr29629.f90 new file mode 100644 index 00000000000..9ccddffb039 --- /dev/null +++ b/libgomp/testsuite/libgomp.fortran/pr29629.f90 @@ -0,0 +1,20 @@ +! PR fortran/29629 +! { dg-do run } + +program pr29629 + integer :: n + n = 10000 + if (any (func(n).ne.10000)) call abort + contains + function func(n) + integer, intent(in) :: n + integer, dimension(n) :: func + integer :: k + func = 0 +!$omp parallel do private(k), reduction(+:func), num_threads(4) + do k = 1, n + func = func + 1 + end do +!$omp end parallel do + end function +end program |