[OpenACC] Use proper location to 'inform' of enclosing parent compute construct
authorThomas Schwinge <thomas@codesourcery.com>
Tue, 3 Nov 2020 21:06:29 +0000 (22:06 +0100)
committerThomas Schwinge <thomas@codesourcery.com>
Tue, 3 Nov 2020 21:26:02 +0000 (22:26 +0100)
commitfab72592d86d11b89a01f0f3c2c9c329d43466c1
tree445a2dc949c8e911cea9fdd89a841d67e4d2522f
parent12d05123053359903c2859c72ce29749662b3ab5
[OpenACC] Use proper location to 'inform' of enclosing parent compute construct

Bug fix for recent commit beddd1762ad2bbe84dd776c54489153f83f21e56 "[OpenACC]
More precise diagnostics for 'gang', 'worker', 'vector' clauses with arguments
on 'loop' only allowed in 'kernels' regions":

> [...], and 'inform' at the location of the enclosing parent
> compute construct/[...].

Now really.

gcc/
* omp-low.c (scan_omp_for) <OpenACC>: Use proper location to
'inform' of enclosing parent compute construct.
gcc/testsuite/
* c-c++-common/goacc/pr92793-1.c: Extend.
* gfortran.dg/goacc/pr92793-1.f90: Likewise.
gcc/omp-low.c
gcc/testsuite/c-c++-common/goacc/pr92793-1.c
gcc/testsuite/gfortran.dg/goacc/pr92793-1.f90