From 8126264b8be7e05fb1ddbeb1df4f29be745f3412 Mon Sep 17 00:00:00 2001 From: jakub Date: Mon, 30 Mar 2015 17:54:05 +0000 Subject: PR fortran/65597 * trans-openmp.c (gfc_trans_omp_do): For !simple simd with explicit linear clause for the iterator set OMP_CLAUSE_LINEAR_NO_COPYIN. For implcitly added !simple OMP_CLAUSE_LINEAR set it too. Use step 1 instead of the original step on the new iterator - count. * testsuite/libgomp.fortran/pr65597.f90: New test. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@221776 138bc75d-0d04-0410-961f-82ee72b054a4 --- libgomp/ChangeLog | 5 +++++ libgomp/testsuite/libgomp.fortran/pr65597.f90 | 21 +++++++++++++++++++++ 2 files changed, 26 insertions(+) create mode 100644 libgomp/testsuite/libgomp.fortran/pr65597.f90 (limited to 'libgomp') diff --git a/libgomp/ChangeLog b/libgomp/ChangeLog index b2e7892b0ef..74a28258e2f 100644 --- a/libgomp/ChangeLog +++ b/libgomp/ChangeLog @@ -1,3 +1,8 @@ +2015-03-30 Jakub Jelinek + + PR fortran/65597 + * testsuite/libgomp.fortran/pr65597.f90: New test. + 2015-03-27 Tom de Vries PR testsuite/65594 diff --git a/libgomp/testsuite/libgomp.fortran/pr65597.f90 b/libgomp/testsuite/libgomp.fortran/pr65597.f90 new file mode 100644 index 00000000000..c19f077753d --- /dev/null +++ b/libgomp/testsuite/libgomp.fortran/pr65597.f90 @@ -0,0 +1,21 @@ +! PR fortran/65597 +! { dg-do run } + + integer :: i, a(151) + a(:) = 0 + !$omp do simd + do i = 1, 151, 31 + a(i) = a(i) + 1 + end do + !$omp do simd linear (i: 31) + do i = 1, 151, 31 + a(i) = a(i) + 1 + end do + do i = 1, 151 + if (mod (i, 31) .eq. 1) then + if (a(i) .ne. 2) call abort + else + if (a(i) .ne. 0) call abort + end if + end do +end -- cgit v1.2.1