[gomp4] [2/3] OpenACC 2.0 support for libgomp - new tests

Thomas Schwinge thomas@codesourcery.com
Thu Nov 13 13:32:00 GMT 2014


Hi!

On Tue, 14 Oct 2014 17:11:42 +0100, Julian Brown <julian@codesourcery.com> wrote:
> --- /dev/null
> +++ b/libgomp/testsuite/libgomp.oacc-c/context-2.c

> +    float *h_X, [...]

> +    h_X = (float *) malloc (N * sizeof (float));

> +    d_X = (float *) acc_copyin (&h_X[0], N * sizeof (float));

> +#pragma acc parallel copyin (h_X[0:N]), copy (h_Y2[0:N]) copyin (alpha)

As made apparent by a testsuite regression, after gomp-4_0-branch commit
r217482,
<http://news.gmane.org/find-root.php?message_id=%3C87fvdncmxg.fsf%40kepler.schwinge.homeip.net%3E>,
this needs to be changed as follows; committed to gomp-4_0-branch in
r217484:

commit 0a74cef871aefd56e577d19864f80e78b6af09e8
Author: tschwinge <tschwinge@138bc75d-0d04-0410-961f-82ee72b054a4>
Date:   Thu Nov 13 13:22:54 2014 +0000

    libgomp testsuite: Fix data clause.
    
    ... after having extended libgomp to actually distinguish between
    "non-force"/"force" semantics.
    
    	libgomp/
    	* testsuite/libgomp.oacc-c-c++-common/context-2.c: Fix data
    	clause.
    
    git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/branches/gomp-4_0-branch@217484 138bc75d-0d04-0410-961f-82ee72b054a4
---
 libgomp/ChangeLog.gomp                                  | 3 +++
 libgomp/testsuite/libgomp.oacc-c-c++-common/context-2.c | 2 +-
 2 files changed, 4 insertions(+), 1 deletion(-)

diff --git libgomp/ChangeLog.gomp libgomp/ChangeLog.gomp
index 254846f..a5a58a0 100644
--- libgomp/ChangeLog.gomp
+++ libgomp/ChangeLog.gomp
@@ -1,5 +1,8 @@
 2014-11-13  Thomas Schwinge  <thomas@codesourcery.com>
 
+	* testsuite/libgomp.oacc-c-c++-common/context-2.c: Fix data
+	clause.
+
 	* target.c (gomp_map_vars_existing): Error out if "force"
 	semantics.
 	(gomp_map_vars): Actually pass kinds to gomp_map_vars_existing.
diff --git libgomp/testsuite/libgomp.oacc-c-c++-common/context-2.c libgomp/testsuite/libgomp.oacc-c-c++-common/context-2.c
index 16464d5..6a52f74 100644
--- libgomp/testsuite/libgomp.oacc-c-c++-common/context-2.c
+++ libgomp/testsuite/libgomp.oacc-c-c++-common/context-2.c
@@ -149,7 +149,7 @@ main (int argc, char **argv)
 
     context_check (pctx);
 
-#pragma acc parallel copyin (h_X[0:N]), copy (h_Y2[0:N]) copyin (alpha)
+#pragma acc parallel present (h_X[0:N]), copy (h_Y2[0:N]) copyin (alpha)
     {
         int i;
 


Grüße,
 Thomas
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 472 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20141113/a23fd763/attachment.sig>


More information about the Gcc-patches mailing list