This is the mail archive of the mailing list for the GCC project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH, OpenACC, 4/8] Multi-dimensional dynamic array support for OpenACC data clauses, omp-low: dynamic array descriptor creation

On 2018/10/16 8:56 PM, Chung-Lin Tang wrote:
The next two patches are the bulk of the compiler patch in the middle-ends.

The first patch here, implements the creation of dynamic array descriptors to
pass to the runtime, a different way than completely using map-clauses.

Because we support arbitrary number of dimensions, adding more map kind cases
may convolute a lot of the compiler/runtime logic handling the long map sequences.

This implementation uses a descriptor struct created on stack, and passes the
pointer to descriptor through to the libgomp runtime, using the exact same receiver field
for the dynamic array.

The libgomp runtime then does its stuff to set things up, and properly adjusts the device-side
receiver field pointer to the on-device created dynamic array structures. I.e. the same receiver
field serves as descriptor address field on the compiler side, and as the actual data address
once we get to device code (a pretty important point needed to clarify).

After the prior revising of libgomp/target.c:gomp_map_vars() to test the first map for
necessity of this dynamic array processing, this patch correspondingly updates scan_omp_target
to reorder related map clauses to the start of the clause chain for OpenACC constructs.

Again, besides the whole revised patch, v1-v2 diff also included.


Attachment: openacc-da-04.omp-low.descr_create.v2.patch
Description: Text document

Attachment: 04-omp-low.descr_create.v1-v2.diff
Description: Text document

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]