OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-old/] [gcc-4.2.2/] [libgomp/] [testsuite/] [libgomp.fortran/] [nestedfn2.f90] - Blame information for rev 867

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 38 julius
! { dg-do run }
2
 
3
  integer :: i
4
  common /c/ i
5
  i = -1
6
!$omp parallel shared (i) num_threads (4)
7
  call test1
8
!$omp end parallel
9
end
10
subroutine test1
11
  integer :: vari
12
  call test2
13
  call test3
14
contains
15
  subroutine test2
16
    use omp_lib
17
    integer :: i
18
    common /c/ i
19
!$omp single
20
    i = omp_get_thread_num ()
21
    call test4
22
!$omp end single copyprivate (vari)
23
  end subroutine test2
24
  subroutine test3
25
    integer :: i
26
    common /c/ i
27
    if (i .lt. 0 .or. i .ge. 4) call abort
28
    if (i + 10 .ne. vari) call abort
29
  end subroutine test3
30
  subroutine test4
31
    use omp_lib
32
    vari = omp_get_thread_num () + 10
33
  end subroutine test4
34
end subroutine test1

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.