mbox series

[0/4] OpenACC 2.6 manual deep copy (repost)

Message ID 20191006223237.81842-1-julian@codesourcery.com
Headers show
Series OpenACC 2.6 manual deep copy (repost) | expand

Message

Julian Brown Oct. 6, 2019, 10:32 p.m. UTC
Hi,

This patch series comprises an updated version of manual deep copy
support for OpenACC 2.6. This was last posted upstream starting here:

  https://gcc.gnu.org/ml/gcc-patches/2018-11/msg00823.html

The reference counting changes from the 3rd patch from that submission
have been reposted a few days ago here:

  https://gcc.gnu.org/ml/gcc-patches/2019-10/msg00238.html

Tested with offloading to nvptx (as a series, with the above refcounting
patch). OK for trunk? (A couple of these patches were approved already;
further commentary will be given on individual patches.)

Thanks,

Julian

Julian Brown (4):
  Add function for pretty-printing OpenACC clause names
  Use gomp_map_val for OpenACC host-to-device address translation
  Factor out duplicate code in gimplify_scan_omp_clauses
  OpenACC 2.6 manual deep copy support (attach/detach)

 gcc/c-family/c-common.h                       |   1 +
 gcc/c-family/c-omp.c                          |  33 ++
 gcc/c-family/c-pragma.h                       |   2 +
 gcc/c/c-parser.c                              |  52 +-
 gcc/c/c-typeck.c                              |  76 ++-
 gcc/cp/parser.c                               |  55 +-
 gcc/cp/semantics.c                            |  98 +++-
 gcc/fortran/gfortran.h                        |   2 +
 gcc/fortran/openmp.c                          | 150 +++--
 gcc/fortran/trans-expr.c                      | 184 +++---
 gcc/fortran/trans-openmp.c                    | 290 +++++++---
 gcc/fortran/trans.h                           |   9 +
 gcc/gimplify.c                                | 525 ++++++++++++------
 gcc/omp-low.c                                 |   3 +
 .../goacc/deep-copy-arrayofstruct.c           |  84 +++
 gcc/testsuite/c-c++-common/goacc/mdc-1.c      |  55 ++
 gcc/testsuite/c-c++-common/goacc/mdc-2.c      |  62 +++
 gcc/testsuite/g++.dg/goacc/mdc.C              |  68 +++
 .../gfortran.dg/goacc/data-clauses.f95        |  38 +-
 .../gfortran.dg/goacc/derived-types-2.f90     |  14 +
 .../gfortran.dg/goacc/derived-types.f90       |  77 +++
 .../gfortran.dg/goacc/enter-exit-data.f95     |  24 +-
 gcc/tree-pretty-print.c                       |  18 +
 include/gomp-constants.h                      |  16 +-
 libgomp/libgomp.h                             |  13 +
 libgomp/libgomp.map                           |  10 +
 libgomp/oacc-mem.c                            |  82 ++-
 libgomp/oacc-parallel.c                       | 201 +++++--
 libgomp/openacc.h                             |   6 +
 libgomp/target.c                              | 194 ++++++-
 .../testsuite/libgomp.oacc-c++/deep-copy-12.C |  72 +++
 .../testsuite/libgomp.oacc-c++/deep-copy-13.C |  72 +++
 .../libgomp.oacc-c-c++-common/deep-copy-1.c   |  24 +
 .../libgomp.oacc-c-c++-common/deep-copy-10.c  |  53 ++
 .../libgomp.oacc-c-c++-common/deep-copy-11.c  |  72 +++
 .../libgomp.oacc-c-c++-common/deep-copy-14.c  |  63 +++
 .../libgomp.oacc-c-c++-common/deep-copy-2.c   |  29 +
 .../libgomp.oacc-c-c++-common/deep-copy-3.c   |  34 ++
 .../libgomp.oacc-c-c++-common/deep-copy-4.c   |  87 +++
 .../libgomp.oacc-c-c++-common/deep-copy-5.c   |  81 +++
 .../libgomp.oacc-c-c++-common/deep-copy-6.c   |  59 ++
 .../libgomp.oacc-c-c++-common/deep-copy-7.c   |  45 ++
 .../libgomp.oacc-c-c++-common/deep-copy-8.c   |  54 ++
 .../libgomp.oacc-c-c++-common/deep-copy-9.c   |  53 ++
 .../libgomp.oacc-fortran/deep-copy-1.f90      |  35 ++
 .../libgomp.oacc-fortran/deep-copy-2.f90      |  33 ++
 .../libgomp.oacc-fortran/deep-copy-3.f90      |  34 ++
 .../libgomp.oacc-fortran/deep-copy-4.f90      |  49 ++
 .../libgomp.oacc-fortran/deep-copy-5.f90      |  57 ++
 .../libgomp.oacc-fortran/deep-copy-6.f90      |  61 ++
 .../libgomp.oacc-fortran/deep-copy-7.f90      |  89 +++
 .../libgomp.oacc-fortran/deep-copy-8.f90      |  41 ++
 .../libgomp.oacc-fortran/derived-type-1.f90   |  28 +
 .../libgomp.oacc-fortran/derivedtype-1.f95    |  30 +
 .../libgomp.oacc-fortran/derivedtype-2.f95    |  41 ++
 .../libgomp.oacc-fortran/multidim-slice.f95   |  50 ++
 .../libgomp.oacc-fortran/update-2.f90         | 284 ++++++++++
 57 files changed, 3598 insertions(+), 474 deletions(-)
 create mode 100644 gcc/testsuite/c-c++-common/goacc/deep-copy-arrayofstruct.c
 create mode 100644 gcc/testsuite/c-c++-common/goacc/mdc-1.c
 create mode 100644 gcc/testsuite/c-c++-common/goacc/mdc-2.c
 create mode 100644 gcc/testsuite/g++.dg/goacc/mdc.C
 create mode 100644 gcc/testsuite/gfortran.dg/goacc/derived-types-2.f90
 create mode 100644 gcc/testsuite/gfortran.dg/goacc/derived-types.f90
 create mode 100644 libgomp/testsuite/libgomp.oacc-c++/deep-copy-12.C
 create mode 100644 libgomp/testsuite/libgomp.oacc-c++/deep-copy-13.C
 create mode 100644 libgomp/testsuite/libgomp.oacc-c-c++-common/deep-copy-1.c
 create mode 100644 libgomp/testsuite/libgomp.oacc-c-c++-common/deep-copy-10.c
 create mode 100644 libgomp/testsuite/libgomp.oacc-c-c++-common/deep-copy-11.c
 create mode 100644 libgomp/testsuite/libgomp.oacc-c-c++-common/deep-copy-14.c
 create mode 100644 libgomp/testsuite/libgomp.oacc-c-c++-common/deep-copy-2.c
 create mode 100644 libgomp/testsuite/libgomp.oacc-c-c++-common/deep-copy-3.c
 create mode 100644 libgomp/testsuite/libgomp.oacc-c-c++-common/deep-copy-4.c
 create mode 100644 libgomp/testsuite/libgomp.oacc-c-c++-common/deep-copy-5.c
 create mode 100644 libgomp/testsuite/libgomp.oacc-c-c++-common/deep-copy-6.c
 create mode 100644 libgomp/testsuite/libgomp.oacc-c-c++-common/deep-copy-7.c
 create mode 100644 libgomp/testsuite/libgomp.oacc-c-c++-common/deep-copy-8.c
 create mode 100644 libgomp/testsuite/libgomp.oacc-c-c++-common/deep-copy-9.c
 create mode 100644 libgomp/testsuite/libgomp.oacc-fortran/deep-copy-1.f90
 create mode 100644 libgomp/testsuite/libgomp.oacc-fortran/deep-copy-2.f90
 create mode 100644 libgomp/testsuite/libgomp.oacc-fortran/deep-copy-3.f90
 create mode 100644 libgomp/testsuite/libgomp.oacc-fortran/deep-copy-4.f90
 create mode 100644 libgomp/testsuite/libgomp.oacc-fortran/deep-copy-5.f90
 create mode 100644 libgomp/testsuite/libgomp.oacc-fortran/deep-copy-6.f90
 create mode 100644 libgomp/testsuite/libgomp.oacc-fortran/deep-copy-7.f90
 create mode 100644 libgomp/testsuite/libgomp.oacc-fortran/deep-copy-8.f90
 create mode 100644 libgomp/testsuite/libgomp.oacc-fortran/derived-type-1.f90
 create mode 100644 libgomp/testsuite/libgomp.oacc-fortran/derivedtype-1.f95
 create mode 100644 libgomp/testsuite/libgomp.oacc-fortran/derivedtype-2.f95
 create mode 100644 libgomp/testsuite/libgomp.oacc-fortran/multidim-slice.f95
 create mode 100644 libgomp/testsuite/libgomp.oacc-fortran/update-2.f90