r277705 - in /trunk: gcc/ChangeLog gcc/fortran/...
burnus@gcc.gnu.org
burnus@gcc.gnu.org
Fri Nov 1 07:59:00 GMT 2019
Author: burnus
Date: Fri Nov 1 07:59:23 2019
New Revision: 277705
URL: https://gcc.gnu.org/viewcvs?rev=277705&root=gcc&view=rev
Log:
OpenMP] use_device_addr/use_device_ptr with Fortran allocatable/pointer arrays
gcc/fortran/
* f95-lang.c (LANG_HOOKS_OMP_ARRAY_DATA): Set to gfc_omp_array_data.
* trans-array.c (gfc_conv_descriptor_data_get): Handle also
REFERENCE_TYPE.
* trans-openmp.c (gfc_omp_array_data): New.
* trans.h (gfc_omp_array_data): New prototype.
gcc/
* hooks.c (hook_tree_tree_bool_null): New.
* hooks.h (hook_tree_tree_bool_null): Declare.
* langhooks-def.h (LANG_HOOKS_OMP_ARRAY_DATA): Define.
(LANG_HOOKS_DECLS): Add it.
* langhooks.h (lang_hooks_for_decls): Add omp_array_data.
* omp-low.c (install_var_field): New mode for Fortran descriptor arrays.
(lower_omp_target): Handle Fortran array with descriptor in
OMP_CLAUSE_USE_DEVICE_ADDR/OMP_CLAUSE_USE_DEVICE_PTR.
libgomp/
* testsuite/libgomp.fortran/use_device_addr-1.f90 (test_nullptr_1,
test_dummy_opt_nullptr_callee_1): Add present but unallocated test.
* testsuite/libgomp.fortran/use_device_addr-2.f90: Likewise.
* testsuite/libgomp.fortran/use_device_addr-3.f90: New.
* testsuite/libgomp.fortran/use_device_addr-4.f90: New.
* testsuite/testsuite/libgomp.fortran/use_device_ptr-1.f90: New.
Added:
trunk/libgomp/testsuite/libgomp.fortran/use_device_addr-3.f90
trunk/libgomp/testsuite/libgomp.fortran/use_device_addr-4.f90
trunk/libgomp/testsuite/libgomp.fortran/use_device_ptr-1.f90
Modified:
trunk/gcc/ChangeLog
trunk/gcc/fortran/ChangeLog
trunk/gcc/fortran/f95-lang.c
trunk/gcc/fortran/trans-array.c
trunk/gcc/fortran/trans-openmp.c
trunk/gcc/fortran/trans.h
trunk/gcc/hooks.c
trunk/gcc/hooks.h
trunk/gcc/langhooks-def.h
trunk/gcc/langhooks.h
trunk/gcc/omp-low.c
trunk/libgomp/ChangeLog
trunk/libgomp/testsuite/libgomp.fortran/use_device_addr-1.f90
trunk/libgomp/testsuite/libgomp.fortran/use_device_addr-2.f90
More information about the Gcc-cvs
mailing list