On Wed, Jun 08, 2016 at 03:28:57PM +0200, Thomas Schwinge wrote: > > [PR c/71381] C/C++ OpenACC cache directive rejects valid syntax > > > > gcc/c/ > > PR c/71381 > > * c-parser.c (c_parser_omp_variable_list) <OMP_CLAUSE__CACHE_>: > > Loosen checking. > > gcc/cp/ > > PR c/71381 > > * parser.c (cp_parser_omp_var_list_no_open) > > <OMP_CLAUSE__CACHE_>: > > Loosen checking. > > gcc/fortran/ > > PR c/71381 > > * openmp.c (gfc_match_oacc_cache): Add comment. > > gcc/testsuite/ > > PR c/71381 > > * c-c++-common/goacc/cache-1.c: Update. Move invalid usage > > tests > > to... > > * c-c++-common/goacc/cache-2.c: ... this new file. > > * gfortran.dg/goacc/cache-1.f95: Move invalid usage tests to... > > * gfortran.dg/goacc/cache-2.f95: ... this new file. > > * gfortran.dg/goacc/coarray.f95: Update OpenACC cache directive > > usage. > > * gfortran.dg/goacc/cray.f95: Likewise. > > * gfortran.dg/goacc/loop-1.f95: Likewise. > > libgomp/ > > PR c/71381 > > * testsuite/libgomp.oacc-c-c++-common/cache-1.c: #include > > "../../../gcc/testsuite/c-c++-common/goacc/cache-1.c". > > * testsuite/libgomp.oacc-fortran/cache-1.f95: New file. > > > > gcc/ > > * omp-low.c (scan_sharing_clauses): Don't expect > > OMP_CLAUSE__CACHE_.
Ok. > > --- gcc/c/c-parser.c > > +++ gcc/c/c-parser.c > > @@ -10601,6 +10601,9 @@ c_parser_omp_variable_list (c_parser *parser, > > switch (kind) > > { > > case OMP_CLAUSE__CACHE_: > > + /* The OpenACC cache directive explicitly only allows "array > > + elements or subarrays". Would it make sense to allow complete > > + arrays as a GNU extension? */ Please try to not add GNU extensions on top of OpenACC, unless strictly necessary. It is better if the compiler is strict and there is interoperability. If you think it should accept something that it doesn't, talk to the OpenACC committee. Jakub