-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add new module,
events_m
, and add interfaces for prif_event_post
,
`prif_event_wait`, and `prif_event_query`.
- Loading branch information
Showing
3 changed files
with
58 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
! Copyright (c), The Regents of the University of California | ||
! Terms of use are as specified in LICENSE.txt | ||
module events_m | ||
use iso_c_binding, only: c_intptr_t, c_int, c_intmax_t | ||
|
||
implicit none | ||
private | ||
public :: prif_event_post, prif_event_wait, prif_event_query | ||
|
||
interface | ||
|
||
module subroutine prif_event_post(image_num, event_var_ptr, stat, errmsg, errmsg_alloc) | ||
implicit none | ||
integer(c_int), intent(in) :: image_num | ||
integer(c_intptr_t), intent(in) :: event_var_ptr | ||
integer(c_int), intent(out), optional :: stat | ||
character(len=*), intent(inout), optional :: errmsg | ||
character(len=:), intent(inout), allocatable, optional :: errmsg_alloc | ||
end subroutine | ||
|
||
module subroutine prif_event_wait(event_var_ptr, until_count, stat, errmsg, errmsg_alloc) | ||
implicit none | ||
integer(c_intptr_t), intent(in) :: event_var_ptr | ||
integer(c_intmax_t), intent(in), optional :: until_count | ||
integer(c_int), intent(out), optional :: stat | ||
character(len=*), intent(inout), optional :: errmsg | ||
character(len=:), intent(inout), allocatable, optional :: errmsg_alloc | ||
end subroutine | ||
|
||
module subroutine prif_event_query(event_var_ptr, count, stat) | ||
implicit none | ||
integer(c_intptr_t), intent(in) :: event_var_ptr | ||
integer(c_intmax_t), intent(out) :: count | ||
integer(c_int), intent(out), optional :: stat | ||
end subroutine | ||
|
||
end interface | ||
|
||
end module events_m |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
! Copyright (c), The Regents of the University of California | ||
! Terms of use are as specified in LICENSE.txt | ||
submodule(events_m) events_s | ||
|
||
implicit none | ||
|
||
contains | ||
|
||
module procedure prif_event_post | ||
end procedure | ||
|
||
module procedure prif_event_wait | ||
end procedure | ||
|
||
module procedure prif_event_query | ||
end procedure | ||
|
||
end submodule events_s |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters