From: Thomas Schwinge <thomas@codesourcery.com>
To: GCC Patches <gcc-patches@gcc.gnu.org>, Jakub Jelinek <jakub@redhat.com>
Cc: Julian Brown <julian@codesourcery.com>,
James Norris <jnorris@codesourcery.com>,
"Joseph S. Myers" <joseph@codesourcery.com>,
Nathan Sidwell <Nathan_Sidwell@mentor.com>,
Cesar Philippidis <cesar@codesourcery.com>
Subject: Re: [OpenACC 0/7] host_data construct
Date: Tue, 02 Feb 2016 13:57:00 -0000 [thread overview]
Message-ID: <8737tbw6yq.fsf@kepler.schwinge.homeip.net> (raw)
In-Reply-To: <877fkwn8p6.fsf@kepler.schwinge.homeip.net>
[-- Attachment #1: Type: text/plain, Size: 5971 bytes --]
Hi!
On Wed, 2 Dec 2015 16:58:45 +0100, I wrote:
> On Mon, 30 Nov 2015 19:30:34 +0000, Julian Brown <julian@codesourcery.com> wrote:
> > --- a/libgomp/oacc-parallel.c
> > +++ b/libgomp/oacc-parallel.c
>
> > +void
> > +GOACC_host_data (int device, size_t mapnum,
> > + void **hostaddrs, size_t *sizes, unsigned short *kinds)
> > +{
> > +[...]
> > +}
>
> Isn't that identical to GOACC_data_start? Can we thus get rid of it?
Yes, we can. As GOACC_host_data has not been part of GCC 5's libgomp
ABI, it's OK to just remove it; committed "as obvious" in r233074:
commit 2bf3f448431be10baa9755df5faeed6b2f6508f8
Author: tschwinge <tschwinge@138bc75d-0d04-0410-961f-82ee72b054a4>
Date: Tue Feb 2 13:53:55 2016 +0000
Merge BUILT_IN_GOACC_HOST_DATA into BUILT_IN_GOACC_DATA_START
gcc/
* omp-builtins.def (BUILT_IN_GOACC_HOST_DATA): Remove.
* omp-low.c (expand_omp_target): Use BUILT_IN_GOACC_DATA_START
instead.
libgomp/
* libgomp.map (GOACC_2.0): Remove GOACC_host_data.
* oacc-parallel.c (GOACC_host_data): Remove function definition.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@233074 138bc75d-0d04-0410-961f-82ee72b054a4
---
gcc/ChangeLog | 6 ++++++
gcc/omp-builtins.def | 2 --
gcc/omp-low.c | 5 +----
libgomp/ChangeLog | 3 +++
libgomp/libgomp.map | 1 -
libgomp/oacc-parallel.c | 40 ----------------------------------------
6 files changed, 10 insertions(+), 47 deletions(-)
diff --git gcc/ChangeLog gcc/ChangeLog
index 05741331..9a2cec8 100644
--- gcc/ChangeLog
+++ gcc/ChangeLog
@@ -1,3 +1,9 @@
+2016-02-02 Thomas Schwinge <thomas@codesourcery.com>
+
+ * omp-builtins.def (BUILT_IN_GOACC_HOST_DATA): Remove.
+ * omp-low.c (expand_omp_target): Use BUILT_IN_GOACC_DATA_START
+ instead.
+
2016-02-02 Richard Biener <rguenther@suse.de>
PR tree-optimization/69606
diff --git gcc/omp-builtins.def gcc/omp-builtins.def
index 60199b0..ea012df 100644
--- gcc/omp-builtins.def
+++ gcc/omp-builtins.def
@@ -47,8 +47,6 @@ DEF_GOACC_BUILTIN (BUILT_IN_GOACC_UPDATE, "GOACC_update",
DEF_GOACC_BUILTIN (BUILT_IN_GOACC_WAIT, "GOACC_wait",
BT_FN_VOID_INT_INT_VAR,
ATTR_NOTHROW_LIST)
-DEF_GOACC_BUILTIN (BUILT_IN_GOACC_HOST_DATA, "GOACC_host_data",
- BT_FN_VOID_INT_SIZE_PTR_PTR_PTR, ATTR_NOTHROW_LIST)
DEF_GOACC_BUILTIN_COMPILER (BUILT_IN_ACC_ON_DEVICE, "acc_on_device",
BT_FN_INT_INT, ATTR_CONST_NOTHROW_LEAF_LIST)
diff --git gcc/omp-low.c gcc/omp-low.c
index 0b70274..d41688b 100644
--- gcc/omp-low.c
+++ gcc/omp-low.c
@@ -13186,6 +13186,7 @@ expand_omp_target (struct omp_region *region)
start_ix = BUILT_IN_GOACC_PARALLEL;
break;
case GF_OMP_TARGET_KIND_OACC_DATA:
+ case GF_OMP_TARGET_KIND_OACC_HOST_DATA:
start_ix = BUILT_IN_GOACC_DATA_START;
break;
case GF_OMP_TARGET_KIND_OACC_UPDATE:
@@ -13197,9 +13198,6 @@ expand_omp_target (struct omp_region *region)
case GF_OMP_TARGET_KIND_OACC_DECLARE:
start_ix = BUILT_IN_GOACC_DECLARE;
break;
- case GF_OMP_TARGET_KIND_OACC_HOST_DATA:
- start_ix = BUILT_IN_GOACC_HOST_DATA;
- break;
default:
gcc_unreachable ();
}
@@ -13324,7 +13322,6 @@ expand_omp_target (struct omp_region *region)
case BUILT_IN_GOACC_DATA_START:
case BUILT_IN_GOACC_DECLARE:
case BUILT_IN_GOMP_TARGET_DATA:
- case BUILT_IN_GOACC_HOST_DATA:
break;
case BUILT_IN_GOMP_TARGET:
case BUILT_IN_GOMP_TARGET_UPDATE:
diff --git libgomp/ChangeLog libgomp/ChangeLog
index 6c9bf6a..250240d 100644
--- libgomp/ChangeLog
+++ libgomp/ChangeLog
@@ -1,5 +1,8 @@
2016-02-02 Thomas Schwinge <thomas@codesourcery.com>
+ * libgomp.map (GOACC_2.0): Remove GOACC_host_data.
+ * oacc-parallel.c (GOACC_host_data): Remove function definition.
+
* testsuite/lib/libgomp.exp: Skip hsa offloading for OpenACC test
cases.
diff --git libgomp/libgomp.map libgomp/libgomp.map
index ea9344d..4d42c42 100644
--- libgomp/libgomp.map
+++ libgomp/libgomp.map
@@ -394,7 +394,6 @@ GOACC_2.0.1 {
global:
GOACC_declare;
GOACC_parallel_keyed;
- GOACC_host_data;
} GOACC_2.0;
GOMP_PLUGIN_1.0 {
diff --git libgomp/oacc-parallel.c libgomp/oacc-parallel.c
index f22ba41..bc24651 100644
--- libgomp/oacc-parallel.c
+++ libgomp/oacc-parallel.c
@@ -490,46 +490,6 @@ GOACC_wait (int async, int num_waits, ...)
goacc_thread ()->dev->openacc.async_wait_all_async_func (acc_async_noval);
}
-void
-GOACC_host_data (int device, size_t mapnum,
- void **hostaddrs, size_t *sizes, unsigned short *kinds)
-{
- bool host_fallback = device == GOMP_DEVICE_HOST_FALLBACK;
- struct target_mem_desc *tgt;
-
-#ifdef HAVE_INTTYPES_H
- gomp_debug (0, "%s: mapnum=%"PRIu64", hostaddrs=%p, size=%p, kinds=%p\n",
- __FUNCTION__, (uint64_t) mapnum, hostaddrs, sizes, kinds);
-#else
- gomp_debug (0, "%s: mapnum=%lu, hostaddrs=%p, sizes=%p, kinds=%p\n",
- __FUNCTION__, (unsigned long) mapnum, hostaddrs, sizes, kinds);
-#endif
-
- goacc_lazy_initialize ();
-
- struct goacc_thread *thr = goacc_thread ();
- struct gomp_device_descr *acc_dev = thr->dev;
-
- /* Host fallback or 'do nothing'. */
- if ((acc_dev->capabilities & GOMP_OFFLOAD_CAP_SHARED_MEM)
- || host_fallback)
- {
- tgt = gomp_map_vars (NULL, 0, NULL, NULL, NULL, NULL, true,
- GOMP_MAP_VARS_OPENACC);
- tgt->prev = thr->mapped_data;
- thr->mapped_data = tgt;
-
- return;
- }
-
- gomp_debug (0, " %s: prepare mappings\n", __FUNCTION__);
- tgt = gomp_map_vars (acc_dev, mapnum, hostaddrs, NULL, sizes, kinds, true,
- GOMP_MAP_VARS_OPENACC);
- gomp_debug (0, " %s: mappings prepared\n", __FUNCTION__);
- tgt->prev = thr->mapped_data;
- thr->mapped_data = tgt;
-}
-
int
GOACC_get_num_threads (void)
{
Grüße
Thomas
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 472 bytes --]
next prev parent reply other threads:[~2016-02-02 13:57 UTC|newest]
Thread overview: 33+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-10-22 19:14 James Norris
2015-10-22 19:15 ` [OpenACC 1/7] host_data construct (C/C++ common) James Norris
2015-10-22 19:15 ` [OpenACC 2/7] host_data construct (C FE) James Norris
2015-10-22 19:16 ` [OpenACC 3/7] host_data construct (C front-end) James Norris
2015-10-22 19:18 ` [OpenACC 4/7] host_data construct (middle end) James Norris
2015-10-22 19:19 ` [OpenACC 5/7] host_data construct (gcc tests) James Norris
2015-10-22 19:20 ` [OpenACC 6/7] host_data construct James Norris
2015-10-22 19:22 ` [OpenACC 7/7] host_data construct (runtime tests) James Norris
2015-10-22 20:42 ` [OpenACC 0/7] host_data construct Joseph Myers
2015-10-22 20:53 ` James Norris
2015-10-23 16:01 ` [Bulk] " James Norris
2015-10-26 18:36 ` Jakub Jelinek
2015-10-27 15:57 ` Cesar Philippidis
2015-11-02 18:33 ` Julian Brown
2015-11-02 19:29 ` Jakub Jelinek
2015-11-12 11:16 ` Julian Brown
2015-11-18 12:48 ` Julian Brown
2015-11-19 13:13 ` Jakub Jelinek
2015-11-19 14:29 ` Julian Brown
2015-11-19 15:57 ` Jakub Jelinek
2015-11-30 19:34 ` Julian Brown
2015-12-01 8:30 ` Jakub Jelinek
2015-12-02 15:27 ` Tom de Vries
2015-12-02 15:59 ` Thomas Schwinge
2015-12-02 19:16 ` Cesar Philippidis
2015-12-02 19:28 ` Steve Kargl
2015-12-02 19:35 ` Jakub Jelinek
2015-12-02 19:54 ` Cesar Philippidis
2015-12-02 22:14 ` [gomp4] " Thomas Schwinge
2016-04-08 13:41 ` Fortran OpenACC host_data construct ICE (was: [gomp4] Re: [OpenACC 0/7] host_data construct) Thomas Schwinge
2016-02-02 13:57 ` Thomas Schwinge [this message]
2015-11-13 15:31 ` [Bulk] [OpenACC 0/7] host_data construct Jakub Jelinek
2015-12-23 11:02 ` Thomas Schwinge
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=8737tbw6yq.fsf@kepler.schwinge.homeip.net \
--to=thomas@codesourcery.com \
--cc=Nathan_Sidwell@mentor.com \
--cc=cesar@codesourcery.com \
--cc=gcc-patches@gcc.gnu.org \
--cc=jakub@redhat.com \
--cc=jnorris@codesourcery.com \
--cc=joseph@codesourcery.com \
--cc=julian@codesourcery.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).