https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111661

--- Comment #1 from Patrick Bégou <patrick.be...@univ-grenoble-alpes.fr> ---
With tab an instantiation of an r2tab type described above by Tobias Burnus
this is what I am doing to enlarge the allocatable tab%val attribute to [n,m]
elements with gcc13.2.
       !$acc exit data delete(tab%val) finalize
       !$acc exit data delete(tab) finalize
       deallocate(tab%val)
       allocate(tab%val(n,m))
       tab%dim1=n
       tab%dim2=m
       !$acc enter data copyin(tab)
       !$acc enter data create(tab%val)

Previously (with nvfortran or ftn) I was using:
       !$acc exit data delete(tab%val) finalize
       deallocate(tab%val)
       allocate(tab%val(n,m))
       tab%dim1=n
       tab%dim2=m
       !$acc update device(tab)
       !$acc enter data create(tab%val)

Unfortunatly, as soon as the user defined type contains more that one
allocatable attribute and only one should be resized, the workaround is no more
usable. The same limitation occur with chained lists uploaded on the GPU if one
of the elements contains an attribute allocatable that must be resize: it is no
more possible to remove and then offload again the tab component on the GPU.

Reply via email to