URL
https://opencores.org/ocsvn/openrisc/openrisc/trunk
Subversion Repositories openrisc
[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [libgomp/] [testsuite/] [libgomp.fortran/] [reduction6.f90] - Rev 735
Compare with Previous | Blame | View Log
! { dg-do run }integer, dimension (6, 6) :: acharacter (36) :: cinteger nthreadsa = 9nthreads = -1call foo (a (2:4, 3:5), nthreads)if (nthreads .eq. 3) thenwrite (c, '(36i1)') aif (c .ne. '999999999999966699966699966699999999') call abortend ifcontainssubroutine foo (b, nthreads)use omp_libinteger, dimension (3:, 5:) :: binteger :: err, nthreadsb = 0err = 0!$omp parallel num_threads (3) reduction (+:b)if (any (b .ne. 0)) then!$omp atomicerr = err + 1end if!$omp masternthreads = omp_get_num_threads ()!$omp end masterb = 2!$omp end parallelif (err .gt. 0) call abortend subroutine fooend
