From ea11ddf3d8fb1759503354dadb5122af21ff775e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Nicolas=20K=C3=83nig?= Date: Sun, 11 Oct 2020 11:32:54 +0200 Subject: Change name of option to -fcoarray=shared and library name to libcaf_shared. gcc/fortran/ChangeLog: * lang.opt: Change name of option to -fcoarray=shared. libgfortran/ChangeLog: * Makefile.am: Change library name to libcaf_shared. * Makefile.in: Regenerated. * configure: Regenerated. * nca/README.native_coarrays: Document change. Correctly handle deallocation of components. gcc/fortran/ChangeLog: * trans-decl.c (gfc_build_builtin_function_decls): Fix types, add some documentation. (gfc_trans_native_coarray): Fix call. * trans.c (gfc_deallocate_with_status): Correctly handle deallocation of components. --- gcc/fortran/lang.opt | 4 ++-- gcc/fortran/trans-decl.c | 3 ++- 2 files changed, 4 insertions(+), 3 deletions(-) (limited to 'gcc') diff --git a/gcc/fortran/lang.opt b/gcc/fortran/lang.opt index e267fb0..6180355 100644 --- a/gcc/fortran/lang.opt +++ b/gcc/fortran/lang.opt @@ -761,7 +761,7 @@ Copy array sections into a contiguous block on procedure entry. fcoarray= Fortran RejectNegative Joined Enum(gfc_fcoarray) Var(flag_coarray) Init(GFC_FCOARRAY_NONE) --fcoarray= Specify which coarray parallelization should be used. +-fcoarray= Specify which coarray parallelization should be used. Enum Name(gfc_fcoarray) Type(enum gfc_fcoarray) UnknownError(Unrecognized option: %qs) @@ -776,7 +776,7 @@ EnumValue Enum(gfc_fcoarray) String(lib) Value(GFC_FCOARRAY_LIB) EnumValue -Enum(gfc_fcoarray) String(native) Value(GFC_FCOARRAY_NATIVE) +Enum(gfc_fcoarray) String(shared) Value(GFC_FCOARRAY_NATIVE) fcheck= Fortran RejectNegative JoinedOrMissing diff --git a/gcc/fortran/trans-decl.c b/gcc/fortran/trans-decl.c index 1973c4d..c5d7fab 100644 --- a/gcc/fortran/trans-decl.c +++ b/gcc/fortran/trans-decl.c @@ -5502,7 +5502,8 @@ gfc_create_module_variable (gfc_symbol * sym) DECL_CONTEXT (decl) = sym->ns->proc_name->backend_decl; rest_of_decl_compilation (decl, 1, 0); - if (flag_coarray == GFC_FCOARRAY_NATIVE && sym->attr.codimension) + if (flag_coarray == GFC_FCOARRAY_NATIVE && sym->attr.codimension + && !sym->attr.allocatable) gfc_trans_native_coarray_static (sym); gfc_module_add_decl (cur_module, decl); -- cgit v1.1