aboutsummaryrefslogtreecommitdiff
path: root/libgomp/loop.c
diff options
context:
space:
mode:
authorJakub Jelinek <jakub@redhat.com>2022-04-20 19:06:17 +0200
committerThomas Schwinge <thomas@codesourcery.com>2022-04-25 23:14:02 +0200
commitb2202431910e30d8505c94d1cb9341cac7080d10 (patch)
tree0d32c5d40834f0b7a5d297398070378dd40e471d /libgomp/loop.c
parent68fd1c9f22ad42536bcb63a4c776004268702b0b (diff)
downloadgcc-b2202431910e30d8505c94d1cb9341cac7080d10.zip
gcc-b2202431910e30d8505c94d1cb9341cac7080d10.tar.gz
gcc-b2202431910e30d8505c94d1cb9341cac7080d10.tar.bz2
fortran: Fix up gfc_trans_oacc_construct [PR104717]
So that move_sese_region_to_fn works properly, OpenMP/OpenACC constructs for which that function is invoked need an extra artificial BIND_EXPR around their body so that we move all variables of the bodies. The C/C++ FEs do that both for OpenMP constructs like OMP_PARALLEL, OMP_TASK or OMP_TARGET and for OpenACC constructs that behave similarly to OMP_TARGET, but the Fortran FE only does that for OpenMP constructs. The following patch does that for OpenACC constructs too. PR fortran/104717 gcc/fortran/ * trans-openmp.cc (gfc_trans_oacc_construct): Wrap construct body in an extra BIND_EXPR. gcc/testsuite/ * gfortran.dg/goacc/pr104717.f90: New test. * gfortran.dg/goacc/privatization-1-compute-loop.f90: Adjust. libgomp/ * testsuite/libgomp.oacc-fortran/privatized-ref-2.f90: Adjust. Co-authored-by: Thomas Schwinge <thomas@codesourcery.com>
Diffstat (limited to 'libgomp/loop.c')
0 files changed, 0 insertions, 0 deletions