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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [gfortran.dg/] [coarray/] [lock_1.f90] - Blame information for rev 694

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 694 jeremybenn
! { dg-do run }
2
!
3
! LOCK/UNLOCK check
4
!
5
! PR fortran/18918
6
!
7
 
8
use iso_fortran_env
9
implicit none
10
 
11
type(lock_type) :: lock[*]
12
integer :: stat
13
logical :: acquired
14
 
15
LOCK(lock)
16
UNLOCK(lock)
17
 
18
stat = 99
19
LOCK(lock, stat=stat)
20
if (stat /= 0) call abort()
21
stat = 99
22
UNLOCK(lock, stat=stat)
23
if (stat /= 0) call abort()
24
 
25
if (this_image() == 1) then
26
  acquired = .false.
27
  LOCK (lock[this_image()], acquired_lock=acquired)
28
  if (.not. acquired) call abort()
29
  UNLOCK (lock[1])
30
end if
31
end
32
 

powered by: WebSVN 2.1.0

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