]> git.ipfire.org Git - thirdparty/gcc.git/commit
Fortran: Add transfer_between_remotes [PR107635]
authorAndre Vehreschild <vehre@gcc.gnu.org>
Fri, 7 Feb 2025 10:25:31 +0000 (11:25 +0100)
committerAndre Vehreschild <vehre@gcc.gnu.org>
Thu, 20 Feb 2025 09:33:54 +0000 (10:33 +0100)
commit8bf0ee8d62b8a08e808344d31354ab713157e15d
treea68c67b2929bcfe28f655a54f264f9dde3202589
parent69eb02682b80b84dd0f562f19821c8c8c37ad243
Fortran: Add transfer_between_remotes [PR107635]

Add the last missing coarray data manipulation routine using remote
accessors.

gcc/fortran/ChangeLog:

PR fortran/107635

* coarray.cc (rewrite_caf_send): Rewrite to
transfer_between_remotes when both sides of the assignment have
a coarray.
(coindexed_code_callback): Prevent duplicate rewrite.
* gfortran.texi: Add documentation for transfer_between_remotes.
* intrinsic.cc (add_subroutines): Add intrinsic symbol for
caf_sendget to allow easy rewrite to transfer_between_remotes.
* trans-decl.cc (gfc_build_builtin_function_decls): Add
prototype for transfer_between_remotes.
* trans-intrinsic.cc (conv_caf_vector_subscript_elem): Mark as
deprecated.
(conv_caf_vector_subscript): Same.
(compute_component_offset): Same.
(conv_expr_ref_to_caf_ref): Same.
(conv_stat_and_team): Extract stat and team from expr.
(gfc_conv_intrinsic_caf_get): Use conv_stat_and_team.
(conv_caf_send_to_remote): Same.
(has_ref_after_cafref): Mark as deprecated.
(conv_caf_sendget): Translate to transfer_between_remotes.
* trans.h: Add prototype for transfer_between_remotes.

libgfortran/ChangeLog:

* caf/libcaf.h: Add prototype for transfer_between_remotes.
* caf/single.c: Implement transfer_between_remotes.

gcc/testsuite/ChangeLog:

* gfortran.dg/coarray_lib_comm_1.f90: Fix up scan_trees.
gcc/fortran/coarray.cc
gcc/fortran/gfortran.texi
gcc/fortran/intrinsic.cc
gcc/fortran/trans-decl.cc
gcc/fortran/trans-intrinsic.cc
gcc/fortran/trans.h
gcc/testsuite/gfortran.dg/coarray_lib_comm_1.f90
libgfortran/caf/libcaf.h
libgfortran/caf/single.c