From patchwork Thu Feb 2 14:19:34 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Thomas Schwinge X-Patchwork-Id: 723038 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3vDhwV6ppCz9s76 for ; Fri, 3 Feb 2017 01:20:09 +1100 (AEDT) Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=gcc.gnu.org header.i=@gcc.gnu.org header.b="fShf843f"; dkim-atps=neutral DomainKey-Signature: a=rsa-sha1; c=nofws; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:from :to:cc:subject:in-reply-to:references:date:message-id :mime-version:content-type:content-transfer-encoding; q=dns; s= default; b=d+aMeRFHyMf5Zt7giIi5AUoepFoF9L3iI+dmRU1MX9L4kL5TsK/XG +aK8f1itrhV3sJG/CSBJ0xUj+ZrgqPSkiC/oLml2Wi3YUlW4u2foazlh9VAyZkzV pCW10xFvmzdsvpUv/HiDdS8RXgD3bQRaHRsApEflLjUkALS740JQmo= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:from :to:cc:subject:in-reply-to:references:date:message-id :mime-version:content-type:content-transfer-encoding; s=default; bh=rJe3KbKEIH67U9KxQCeW6OMPMX4=; b=fShf843fLWVZqU5MLLSMsQVHGvhL ABBWLIFvEfqjgCUJoFsskUERZmJ4EGVTXMw9veItcGtaVBRTd8SKAJQ+J6fQFYLt iAFZx+gmT8PwzKlONAPH/MbD9b5uPAhIF5NFO9XDpulX/Bhkd7Kou9KxiEw3uQtD ZFWsF0v8h/2Jahw= Received: (qmail 105280 invoked by alias); 2 Feb 2017 14:19:55 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Delivered-To: mailing list gcc-patches@gcc.gnu.org Received: (qmail 105269 invoked by uid 89); 2 Feb 2017 14:19:54 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.9 required=5.0 tests=AWL, BAYES_00, RCVD_IN_DNSWL_NONE, SPF_PASS, URIBL_RED autolearn=ham version=3.3.2 spammy=1, 16, 1, 19, plugins X-HELO: relay1.mentorg.com Received: from relay1.mentorg.com (HELO relay1.mentorg.com) (192.94.38.131) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Thu, 02 Feb 2017 14:19:44 +0000 Received: from nat-ies.mentorg.com ([192.94.31.2] helo=svr-ies-mbx-01.mgc.mentorg.com) by relay1.mentorg.com with esmtp id 1cZIEe-00056A-QQ from Thomas_Schwinge@mentor.com ; Thu, 02 Feb 2017 06:19:41 -0800 Received: from hertz.schwinge.homeip.net (137.202.0.87) by svr-ies-mbx-01.mgc.mentorg.com (139.181.222.1) with Microsoft SMTP Server (TLS) id 15.0.1210.3; Thu, 2 Feb 2017 14:19:37 +0000 From: Thomas Schwinge To: Jakub Jelinek CC: Subject: Re: libgomp: Normalize the names of a few functions of the libgomp plugin API In-Reply-To: <20170202122711.GU14051@tucnak> References: <874m0kx3l5.fsf@hertz.schwinge.homeip.net> <20170127092842.GS1867@tucnak> <87efzjuw4h.fsf@hertz.schwinge.homeip.net> <87bmuku6ia.fsf@hertz.schwinge.homeip.net> <20170202122711.GU14051@tucnak> User-Agent: Notmuch/0.9-101-g81dad07 (http://notmuchmail.org) Emacs/24.5.1 (x86_64-pc-linux-gnu) Date: Thu, 2 Feb 2017 15:19:34 +0100 Message-ID: <878tpou13d.fsf@hertz.schwinge.homeip.net> MIME-Version: 1.0 X-ClientProxiedBy: svr-ies-mbx-01.mgc.mentorg.com (139.181.222.1) To svr-ies-mbx-01.mgc.mentorg.com (139.181.222.1) Hi! On Thu, 2 Feb 2017 13:27:11 +0100, Jakub Jelinek wrote: > On Thu, Feb 02, 2017 at 01:22:37PM +0100, Thomas Schwinge wrote: > > On Tue, 31 Jan 2017 15:44:46 +0100, I wrote: > > > --- libgomp/libgomp.h > > > +++ libgomp/libgomp.h > > > @@ -882,31 +882,35 @@ typedef struct acc_dispatch_t > > > > > + __typeof (GOMP_OFFLOAD_openacc_parallel) *exec_func; > > > > As can be seen here, for a handful of functions, the name of the > > implementation in the plugins ("GOMP_OFFLOAD_openacc_parallel") doesn't > > match the name used in libgomp proper ("openacc.exec_func"). Here is a > > patch to adjust these. OK for trunk? If not now, then in next stage 1? > > Ok for trunk now Thanks for the quick review! > otherwise we'd have to bump the plugin interface in GCC8, even > when we don't know if we'll need to do that. I don't think that's actually a concern: this changes the libgomp <-> libgomp plugin interface only, for which versioning is not a concern. Anyway, without changes committed to trunk in r245125: commit 65caa53b3e767f1df02673f25f281926d11219a7 Author: tschwinge Date: Thu Feb 2 14:13:57 2017 +0000 libgomp: Normalize the names of a few functions of the libgomp plugin API libgomp/ * libgomp-plugin.h (GOMP_OFFLOAD_openacc_parallel): Rename to GOMP_OFFLOAD_openacc_exec. Adjust all users. (GOMP_OFFLOAD_openacc_get_current_cuda_device): Rename to GOMP_OFFLOAD_openacc_cuda_get_current_device. Adjust all users. (GOMP_OFFLOAD_openacc_get_current_cuda_context): Rename to GOMP_OFFLOAD_openacc_cuda_get_current_context. Adjust all users. (GOMP_OFFLOAD_openacc_get_cuda_stream): Rename to GOMP_OFFLOAD_openacc_cuda_get_stream. Adjust all users. (GOMP_OFFLOAD_openacc_set_cuda_stream): Rename to GOMP_OFFLOAD_openacc_cuda_set_stream. Adjust all users. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@245125 138bc75d-0d04-0410-961f-82ee72b054a4 --- libgomp/ChangeLog | 13 +++++++++++++ libgomp/libgomp-plugin.h | 12 ++++++------ libgomp/libgomp.h | 10 +++++----- libgomp/plugin/plugin-nvptx.c | 14 +++++++------- libgomp/target.c | 10 +++++----- 5 files changed, 36 insertions(+), 23 deletions(-) Grüße Thomas diff --git libgomp/ChangeLog libgomp/ChangeLog index 829a30f..5f05cdb 100644 --- libgomp/ChangeLog +++ libgomp/ChangeLog @@ -1,3 +1,16 @@ +2017-02-02 Thomas Schwinge + + * libgomp-plugin.h (GOMP_OFFLOAD_openacc_parallel): Rename to + GOMP_OFFLOAD_openacc_exec. Adjust all users. + (GOMP_OFFLOAD_openacc_get_current_cuda_device): Rename to + GOMP_OFFLOAD_openacc_cuda_get_current_device. Adjust all users. + (GOMP_OFFLOAD_openacc_get_current_cuda_context): Rename to + GOMP_OFFLOAD_openacc_cuda_get_current_context. Adjust all users. + (GOMP_OFFLOAD_openacc_get_cuda_stream): Rename to + GOMP_OFFLOAD_openacc_cuda_get_stream. Adjust all users. + (GOMP_OFFLOAD_openacc_set_cuda_stream): Rename to + GOMP_OFFLOAD_openacc_cuda_set_stream. Adjust all users. + 2017-01-31 Thomas Schwinge * libgomp-plugin.h: #include . diff --git libgomp/libgomp-plugin.h libgomp/libgomp-plugin.h index fba45ee..ff81350 100644 --- libgomp/libgomp-plugin.h +++ libgomp/libgomp-plugin.h @@ -93,8 +93,8 @@ extern bool GOMP_OFFLOAD_dev2dev (int, void *, const void *, size_t); extern bool GOMP_OFFLOAD_can_run (void *); extern void GOMP_OFFLOAD_run (int, void *, void *, void **); extern void GOMP_OFFLOAD_async_run (int, void *, void *, void **, void *); -extern void GOMP_OFFLOAD_openacc_parallel (void (*) (void *), size_t, void **, - void **, int, unsigned *, void *); +extern void GOMP_OFFLOAD_openacc_exec (void (*) (void *), size_t, void **, + void **, int, unsigned *, void *); extern void GOMP_OFFLOAD_openacc_register_async_cleanup (void *, int); extern int GOMP_OFFLOAD_openacc_async_test (int); extern int GOMP_OFFLOAD_openacc_async_test_all (void); @@ -105,10 +105,10 @@ extern void GOMP_OFFLOAD_openacc_async_wait_all_async (int); extern void GOMP_OFFLOAD_openacc_async_set_async (int); extern void *GOMP_OFFLOAD_openacc_create_thread_data (int); extern void GOMP_OFFLOAD_openacc_destroy_thread_data (void *); -extern void *GOMP_OFFLOAD_openacc_get_current_cuda_device (void); -extern void *GOMP_OFFLOAD_openacc_get_current_cuda_context (void); -extern void *GOMP_OFFLOAD_openacc_get_cuda_stream (int); -extern int GOMP_OFFLOAD_openacc_set_cuda_stream (int, void *); +extern void *GOMP_OFFLOAD_openacc_cuda_get_current_device (void); +extern void *GOMP_OFFLOAD_openacc_cuda_get_current_context (void); +extern void *GOMP_OFFLOAD_openacc_cuda_get_stream (int); +extern int GOMP_OFFLOAD_openacc_cuda_set_stream (int, void *); #ifdef __cplusplus } diff --git libgomp/libgomp.h libgomp/libgomp.h index 6dfe9aa..1769a48 100644 --- libgomp/libgomp.h +++ libgomp/libgomp.h @@ -882,7 +882,7 @@ typedef struct acc_dispatch_t struct target_mem_desc *data_environ; /* Execute. */ - __typeof (GOMP_OFFLOAD_openacc_parallel) *exec_func; + __typeof (GOMP_OFFLOAD_openacc_exec) *exec_func; /* Async cleanup callback registration. */ __typeof (GOMP_OFFLOAD_openacc_register_async_cleanup) @@ -905,12 +905,12 @@ typedef struct acc_dispatch_t /* NVIDIA target specific routines. */ struct { - __typeof (GOMP_OFFLOAD_openacc_get_current_cuda_device) + __typeof (GOMP_OFFLOAD_openacc_cuda_get_current_device) *get_current_device_func; - __typeof (GOMP_OFFLOAD_openacc_get_current_cuda_context) + __typeof (GOMP_OFFLOAD_openacc_cuda_get_current_context) *get_current_context_func; - __typeof (GOMP_OFFLOAD_openacc_get_cuda_stream) *get_stream_func; - __typeof (GOMP_OFFLOAD_openacc_set_cuda_stream) *set_stream_func; + __typeof (GOMP_OFFLOAD_openacc_cuda_get_stream) *get_stream_func; + __typeof (GOMP_OFFLOAD_openacc_cuda_set_stream) *set_stream_func; } cuda; } acc_dispatch_t; diff --git libgomp/plugin/plugin-nvptx.c libgomp/plugin/plugin-nvptx.c index 4144218..0284c7f 100644 --- libgomp/plugin/plugin-nvptx.c +++ libgomp/plugin/plugin-nvptx.c @@ -1922,9 +1922,9 @@ GOMP_OFFLOAD_dev2dev (int ord, void *dst, const void *src, size_t n) void (*device_run) (int n, void *fn_ptr, void *vars) = NULL; void -GOMP_OFFLOAD_openacc_parallel (void (*fn) (void *), size_t mapnum, - void **hostaddrs, void **devaddrs, - int async, unsigned *dims, void *targ_mem_desc) +GOMP_OFFLOAD_openacc_exec (void (*fn) (void *), size_t mapnum, + void **hostaddrs, void **devaddrs, + int async, unsigned *dims, void *targ_mem_desc) { nvptx_exec (fn, mapnum, hostaddrs, devaddrs, async, dims, targ_mem_desc); } @@ -2014,13 +2014,13 @@ GOMP_OFFLOAD_openacc_destroy_thread_data (void *data) } void * -GOMP_OFFLOAD_openacc_get_current_cuda_device (void) +GOMP_OFFLOAD_openacc_cuda_get_current_device (void) { return nvptx_get_current_cuda_device (); } void * -GOMP_OFFLOAD_openacc_get_current_cuda_context (void) +GOMP_OFFLOAD_openacc_cuda_get_current_context (void) { return nvptx_get_current_cuda_context (); } @@ -2028,7 +2028,7 @@ GOMP_OFFLOAD_openacc_get_current_cuda_context (void) /* NOTE: This returns a CUstream, not a ptx_stream pointer. */ void * -GOMP_OFFLOAD_openacc_get_cuda_stream (int async) +GOMP_OFFLOAD_openacc_cuda_get_stream (int async) { return nvptx_get_cuda_stream (async); } @@ -2036,7 +2036,7 @@ GOMP_OFFLOAD_openacc_get_cuda_stream (int async) /* NOTE: This takes a CUstream, not a ptx_stream pointer. */ int -GOMP_OFFLOAD_openacc_set_cuda_stream (int async, void *stream) +GOMP_OFFLOAD_openacc_cuda_set_stream (int async, void *stream) { return nvptx_set_cuda_stream (async, stream); } diff --git libgomp/target.c libgomp/target.c index 26d5aba..3dd119f 100644 --- libgomp/target.c +++ libgomp/target.c @@ -2399,7 +2399,7 @@ gomp_load_plugin_for_device (struct gomp_device_descr *device, } if (device->capabilities & GOMP_OFFLOAD_CAP_OPENACC_200) { - if (!DLSYM_OPT (openacc.exec, openacc_parallel) + if (!DLSYM_OPT (openacc.exec, openacc_exec) || !DLSYM_OPT (openacc.register_async_cleanup, openacc_register_async_cleanup) || !DLSYM_OPT (openacc.async_test, openacc_async_test) @@ -2423,11 +2423,11 @@ gomp_load_plugin_for_device (struct gomp_device_descr *device, unsigned cuda = 0; cuda += DLSYM_OPT (openacc.cuda.get_current_device, - openacc_get_current_cuda_device); + openacc_cuda_get_current_device); cuda += DLSYM_OPT (openacc.cuda.get_current_context, - openacc_get_current_cuda_context); - cuda += DLSYM_OPT (openacc.cuda.get_stream, openacc_get_cuda_stream); - cuda += DLSYM_OPT (openacc.cuda.set_stream, openacc_set_cuda_stream); + openacc_cuda_get_current_context); + cuda += DLSYM_OPT (openacc.cuda.get_stream, openacc_cuda_get_stream); + cuda += DLSYM_OPT (openacc.cuda.set_stream, openacc_cuda_set_stream); if (cuda && cuda != 4) { /* Make sure all the CUDA functions are there if any of them are. */ Backported to gomp-4_0-branch in r245126: commit bc818cb3d8d8a5582aa35e667594102670a76c7a Author: tschwinge Date: Thu Feb 2 14:15:17 2017 +0000 libgomp: Normalize the names of a few functions of the libgomp plugin API Backport from trunk r245125: libgomp/ * libgomp-plugin.h (GOMP_OFFLOAD_openacc_parallel): Rename to GOMP_OFFLOAD_openacc_exec. Adjust all users. (GOMP_OFFLOAD_openacc_get_current_cuda_device): Rename to GOMP_OFFLOAD_openacc_cuda_get_current_device. Adjust all users. (GOMP_OFFLOAD_openacc_get_current_cuda_context): Rename to GOMP_OFFLOAD_openacc_cuda_get_current_context. Adjust all users. (GOMP_OFFLOAD_openacc_get_cuda_stream): Rename to GOMP_OFFLOAD_openacc_cuda_get_stream. Adjust all users. (GOMP_OFFLOAD_openacc_set_cuda_stream): Rename to GOMP_OFFLOAD_openacc_cuda_set_stream. Adjust all users. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/branches/gomp-4_0-branch@245126 138bc75d-0d04-0410-961f-82ee72b054a4 --- libgomp/ChangeLog.gomp | 16 ++++++++++++++++ libgomp/libgomp-plugin.h | 12 ++++++------ libgomp/libgomp.h | 10 +++++----- libgomp/plugin/plugin-nvptx.c | 14 +++++++------- libgomp/target.c | 10 +++++----- 5 files changed, 39 insertions(+), 23 deletions(-) diff --git libgomp/ChangeLog.gomp libgomp/ChangeLog.gomp index 78f64207..17b10ef 100644 --- libgomp/ChangeLog.gomp +++ libgomp/ChangeLog.gomp @@ -1,3 +1,19 @@ +2017-02-02 Thomas Schwinge + + Backport from trunk r245125: + 2017-02-02 Thomas Schwinge + + * libgomp-plugin.h (GOMP_OFFLOAD_openacc_parallel): Rename to + GOMP_OFFLOAD_openacc_exec. Adjust all users. + (GOMP_OFFLOAD_openacc_get_current_cuda_device): Rename to + GOMP_OFFLOAD_openacc_cuda_get_current_device. Adjust all users. + (GOMP_OFFLOAD_openacc_get_current_cuda_context): Rename to + GOMP_OFFLOAD_openacc_cuda_get_current_context. Adjust all users. + (GOMP_OFFLOAD_openacc_get_cuda_stream): Rename to + GOMP_OFFLOAD_openacc_cuda_get_stream. Adjust all users. + (GOMP_OFFLOAD_openacc_set_cuda_stream): Rename to + GOMP_OFFLOAD_openacc_cuda_set_stream. Adjust all users. + 2017-01-31 Thomas Schwinge Backport from trunk r245062: diff --git libgomp/libgomp-plugin.h libgomp/libgomp-plugin.h index fba45ee..ff81350 100644 --- libgomp/libgomp-plugin.h +++ libgomp/libgomp-plugin.h @@ -93,8 +93,8 @@ extern bool GOMP_OFFLOAD_dev2dev (int, void *, const void *, size_t); extern bool GOMP_OFFLOAD_can_run (void *); extern void GOMP_OFFLOAD_run (int, void *, void *, void **); extern void GOMP_OFFLOAD_async_run (int, void *, void *, void **, void *); -extern void GOMP_OFFLOAD_openacc_parallel (void (*) (void *), size_t, void **, - void **, int, unsigned *, void *); +extern void GOMP_OFFLOAD_openacc_exec (void (*) (void *), size_t, void **, + void **, int, unsigned *, void *); extern void GOMP_OFFLOAD_openacc_register_async_cleanup (void *, int); extern int GOMP_OFFLOAD_openacc_async_test (int); extern int GOMP_OFFLOAD_openacc_async_test_all (void); @@ -105,10 +105,10 @@ extern void GOMP_OFFLOAD_openacc_async_wait_all_async (int); extern void GOMP_OFFLOAD_openacc_async_set_async (int); extern void *GOMP_OFFLOAD_openacc_create_thread_data (int); extern void GOMP_OFFLOAD_openacc_destroy_thread_data (void *); -extern void *GOMP_OFFLOAD_openacc_get_current_cuda_device (void); -extern void *GOMP_OFFLOAD_openacc_get_current_cuda_context (void); -extern void *GOMP_OFFLOAD_openacc_get_cuda_stream (int); -extern int GOMP_OFFLOAD_openacc_set_cuda_stream (int, void *); +extern void *GOMP_OFFLOAD_openacc_cuda_get_current_device (void); +extern void *GOMP_OFFLOAD_openacc_cuda_get_current_context (void); +extern void *GOMP_OFFLOAD_openacc_cuda_get_stream (int); +extern int GOMP_OFFLOAD_openacc_cuda_set_stream (int, void *); #ifdef __cplusplus } diff --git libgomp/libgomp.h libgomp/libgomp.h index 3896022..f4bfc06 100644 --- libgomp/libgomp.h +++ libgomp/libgomp.h @@ -866,7 +866,7 @@ typedef struct acc_dispatch_t struct target_mem_desc *data_environ; /* Execute. */ - __typeof (GOMP_OFFLOAD_openacc_parallel) *exec_func; + __typeof (GOMP_OFFLOAD_openacc_exec) *exec_func; /* Async cleanup callback registration. */ __typeof (GOMP_OFFLOAD_openacc_register_async_cleanup) @@ -889,12 +889,12 @@ typedef struct acc_dispatch_t /* NVIDIA target specific routines. */ struct { - __typeof (GOMP_OFFLOAD_openacc_get_current_cuda_device) + __typeof (GOMP_OFFLOAD_openacc_cuda_get_current_device) *get_current_device_func; - __typeof (GOMP_OFFLOAD_openacc_get_current_cuda_context) + __typeof (GOMP_OFFLOAD_openacc_cuda_get_current_context) *get_current_context_func; - __typeof (GOMP_OFFLOAD_openacc_get_cuda_stream) *get_stream_func; - __typeof (GOMP_OFFLOAD_openacc_set_cuda_stream) *set_stream_func; + __typeof (GOMP_OFFLOAD_openacc_cuda_get_stream) *get_stream_func; + __typeof (GOMP_OFFLOAD_openacc_cuda_set_stream) *set_stream_func; } cuda; } acc_dispatch_t; diff --git libgomp/plugin/plugin-nvptx.c libgomp/plugin/plugin-nvptx.c index a05b399..79c58c6 100644 --- libgomp/plugin/plugin-nvptx.c +++ libgomp/plugin/plugin-nvptx.c @@ -1733,9 +1733,9 @@ GOMP_OFFLOAD_host2dev (int ord, void *dst, const void *src, size_t n) void (*device_run) (int n, void *fn_ptr, void *vars) = NULL; void -GOMP_OFFLOAD_openacc_parallel (void (*fn) (void *), size_t mapnum, - void **hostaddrs, void **devaddrs, - int async, unsigned *dims, void *targ_mem_desc) +GOMP_OFFLOAD_openacc_exec (void (*fn) (void *), size_t mapnum, + void **hostaddrs, void **devaddrs, + int async, unsigned *dims, void *targ_mem_desc) { nvptx_exec (fn, mapnum, hostaddrs, devaddrs, async, dims, targ_mem_desc); } @@ -1825,13 +1825,13 @@ GOMP_OFFLOAD_openacc_destroy_thread_data (void *data) } void * -GOMP_OFFLOAD_openacc_get_current_cuda_device (void) +GOMP_OFFLOAD_openacc_cuda_get_current_device (void) { return nvptx_get_current_cuda_device (); } void * -GOMP_OFFLOAD_openacc_get_current_cuda_context (void) +GOMP_OFFLOAD_openacc_cuda_get_current_context (void) { return nvptx_get_current_cuda_context (); } @@ -1839,7 +1839,7 @@ GOMP_OFFLOAD_openacc_get_current_cuda_context (void) /* NOTE: This returns a CUstream, not a ptx_stream pointer. */ void * -GOMP_OFFLOAD_openacc_get_cuda_stream (int async) +GOMP_OFFLOAD_openacc_cuda_get_stream (int async) { return nvptx_get_cuda_stream (async); } @@ -1847,7 +1847,7 @@ GOMP_OFFLOAD_openacc_get_cuda_stream (int async) /* NOTE: This takes a CUstream, not a ptx_stream pointer. */ int -GOMP_OFFLOAD_openacc_set_cuda_stream (int async, void *stream) +GOMP_OFFLOAD_openacc_cuda_set_stream (int async, void *stream) { return nvptx_set_cuda_stream (async, stream); } diff --git libgomp/target.c libgomp/target.c index 590b7dd..6bfcd75 100644 --- libgomp/target.c +++ libgomp/target.c @@ -2855,7 +2855,7 @@ gomp_load_plugin_for_device (struct gomp_device_descr *device, } if (device->capabilities & GOMP_OFFLOAD_CAP_OPENACC_200) { - if (!DLSYM_OPT (openacc.exec, openacc_parallel) + if (!DLSYM_OPT (openacc.exec, openacc_exec) || !DLSYM_OPT (openacc.register_async_cleanup, openacc_register_async_cleanup) || !DLSYM_OPT (openacc.async_test, openacc_async_test) @@ -2879,11 +2879,11 @@ gomp_load_plugin_for_device (struct gomp_device_descr *device, unsigned cuda = 0; cuda += DLSYM_OPT (openacc.cuda.get_current_device, - openacc_get_current_cuda_device); + openacc_cuda_get_current_device); cuda += DLSYM_OPT (openacc.cuda.get_current_context, - openacc_get_current_cuda_context); - cuda += DLSYM_OPT (openacc.cuda.get_stream, openacc_get_cuda_stream); - cuda += DLSYM_OPT (openacc.cuda.set_stream, openacc_set_cuda_stream); + openacc_cuda_get_current_context); + cuda += DLSYM_OPT (openacc.cuda.get_stream, openacc_cuda_get_stream); + cuda += DLSYM_OPT (openacc.cuda.set_stream, openacc_cuda_set_stream); if (cuda && cuda != 4) { /* Make sure all the CUDA functions are there if any of them are. */