https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69090
iverbin at gcc dot gnu.org changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |iverbin at gcc dot gnu.org --- Comment #4 from iverbin at gcc dot gnu.org --- (In reply to Alexander Monakov from comment #0) > Compiling and running the following testcase with non-shared-memory > accelerator segfaults in the target region, because only pointed-to data of > the allocatable array is copied, but not the array structure (.data, .offset > fields) itself. From my reading of the OpenMP spec, allocatable arrays are > not explicitely allowed in the 'declare target' directive, so the code is > ill-formed. However, no diagnostic is issued, and generally I don't know > what GCC intends to do here. Do you mean *global* allocatable arrays, or locals fail too? We discussed it a bit here: https://gcc.gnu.org/ml/gcc/2015-03/msg00238.html There is also a discussion in OpenMP ML about clarifying the spec; and as per my understanding global allocatable arrays are not allowed by OpenMP 4.5, so it would be nice to have a diagnostic instead of segfault.