aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTobias Burnus <tobias@codesourcery.com>2019-12-13 07:58:53 +0000
committerTobias Burnus <burnus@gcc.gnu.org>2019-12-13 08:58:53 +0100
commit7858bb9693e5a3c39e2cc5aede341895a9e6d1b3 (patch)
tree3134206960ee6ca2a1cd8835b413a2c19f463c50
parent396c2a9842f0f565b86efcb41bb3386da5dca889 (diff)
downloadgcc-7858bb9693e5a3c39e2cc5aede341895a9e6d1b3.zip
gcc-7858bb9693e5a3c39e2cc5aede341895a9e6d1b3.tar.gz
gcc-7858bb9693e5a3c39e2cc5aede341895a9e6d1b3.tar.bz2
libgomp/openacc.f90 – clean-up public/private attributes
libgomp/ * openacc.f90 (module openacc_kinds): Use 'PUBLIC' to mark all symbols as public except for the 'use …, only' imported symbol, which is private. (module openacc): Default to 'PRIVATE' to exclude openacc_internal; mark all symbols from module openacc_kinds as PUBLIC; add missing PUBLIC attributes for acc_copyout_finalize and acc_delete_finalize. From-SVN: r279337
-rw-r--r--libgomp/ChangeLog9
-rw-r--r--libgomp/openacc.f9020
2 files changed, 20 insertions, 9 deletions
diff --git a/libgomp/ChangeLog b/libgomp/ChangeLog
index dda2d9a..136ba6c 100644
--- a/libgomp/ChangeLog
+++ b/libgomp/ChangeLog
@@ -1,3 +1,12 @@
+2019-12-13 Tobias Burnus <tobias@codesourcery.com>
+
+ * openacc.f90 (module openacc_kinds): Use 'PUBLIC' to mark all symbols
+ as public except for the 'use …, only' imported symbol, which is
+ private.
+ (module openacc): Default to 'PRIVATE' to exclude openacc_internal; mark
+ all symbols from module openacc_kinds as PUBLIC; add missing PUBLIC
+ attributes for acc_copyout_finalize and acc_delete_finalize.
+
2019-12-11 Jakub Jelinek <jakub@redhat.com>
PR fortran/92899
diff --git a/libgomp/openacc.f90 b/libgomp/openacc.f90
index 831a157..b37f187 100644
--- a/libgomp/openacc.f90
+++ b/libgomp/openacc.f90
@@ -31,13 +31,12 @@ module openacc_kinds
use iso_fortran_env, only: int32
implicit none
+ public
private :: int32
- public :: acc_device_kind
- integer, parameter :: acc_device_kind = int32
+ ! When adding items, also update 'public' setting in 'module openmp' below.
- public :: acc_device_none, acc_device_default, acc_device_host
- public :: acc_device_not_host, acc_device_nvidia
+ integer, parameter :: acc_device_kind = int32
! Keep in sync with include/gomp-constants.h.
integer (acc_device_kind), parameter :: acc_device_none = 0
@@ -48,16 +47,11 @@ module openacc_kinds
integer (acc_device_kind), parameter :: acc_device_nvidia = 5
integer (acc_device_kind), parameter :: acc_device_gcn = 8
- public :: acc_handle_kind
-
integer, parameter :: acc_handle_kind = int32
- public :: acc_async_noval, acc_async_sync
-
! Keep in sync with include/gomp-constants.h.
integer (acc_handle_kind), parameter :: acc_async_noval = -1
integer (acc_handle_kind), parameter :: acc_async_sync = -2
-
end module
module openacc_internal
@@ -717,6 +711,13 @@ module openacc
use openacc_internal
implicit none
+ private
+ ! From openacc_kinds
+ public :: acc_device_kind, acc_handle_kind
+ public :: acc_device_none, acc_device_default, acc_device_host
+ public :: acc_device_not_host, acc_device_nvidia, acc_device_gcn
+ public :: acc_async_noval, acc_async_sync
+
public :: openacc_version
public :: acc_get_num_devices, acc_set_device_type, acc_get_device_type
@@ -730,6 +731,7 @@ module openacc
public :: acc_update_device, acc_update_self, acc_is_present
public :: acc_copyin_async, acc_create_async, acc_copyout_async
public :: acc_delete_async, acc_update_device_async, acc_update_self_async
+ public :: acc_copyout_finalize, acc_delete_finalize
integer, parameter :: openacc_version = 201306