Re: OpenACC C front end maintenance: c_parser_oacc_single_int_clause (was: [OpenACC] num_gangs, num_workers and vector_length in c++)

2017-05-10 Thread Jakub Jelinek
On Tue, May 09, 2017 at 11:27:14PM +0200, Thomas Schwinge wrote: > Hi! > > On Wed, 4 Nov 2015 14:10:29 -0800, Cesar Philippidis > wrote: > > > [...] > > > > Thanks. I've applied this patch to trunk. > > > gcc/cp/ > > * (cp_parser_oacc_single_int_clause): New

OpenACC C front end maintenance: c_parser_oacc_single_int_clause (was: [OpenACC] num_gangs, num_workers and vector_length in c++)

2017-05-09 Thread Thomas Schwinge
Hi! On Wed, 4 Nov 2015 14:10:29 -0800, Cesar Philippidis wrote: > > [...] > > Thanks. I've applied this patch to trunk. > gcc/cp/ > * (cp_parser_oacc_single_int_clause): New function. > (cp_parser_oacc_clause_vector_length): Delete. >

Re: [OpenACC] num_gangs, num_workers and vector_length in c++

2015-11-04 Thread Cesar Philippidis
x 12452e6..4f6cd2d 100644 --- a/gcc/cp/parser.c +++ b/gcc/cp/parser.c @@ -29590,6 +29590,39 @@ cp_parser_oacc_simple_clause (cp_parser * /* parser */, return c; } + /* OpenACC: + num_gangs ( expression ) + num_workers ( expression ) + vector_length ( expression ) */ + +st

Re: [OpenACC] num_gangs, num_workers and vector_length in c++

2015-11-04 Thread Jason Merrill
On 10/30/2015 05:21 PM, Cesar Philippidis wrote: On 10/30/2015 10:05 AM, Jakub Jelinek wrote: On Fri, Oct 30, 2015 at 07:42:39AM -0700, Cesar Philippidis wrote: Another thing is what Jason as C++ maintainer wants, it is nice to get rid of some code redundancies, on the other side the fact

Re: [OpenACC] num_gangs, num_workers and vector_length in c++

2015-10-30 Thread Cesar Philippidis
On 10/30/2015 10:05 AM, Jakub Jelinek wrote: > On Fri, Oct 30, 2015 at 07:42:39AM -0700, Cesar Philippidis wrote: >>> Another thing is what Jason as C++ maintainer wants, it is nice to get rid >>> of some code redundancies, on the other side the fact that there is one >>> function per

Re: [OpenACC] num_gangs, num_workers and vector_length in c++

2015-10-30 Thread Jakub Jelinek
On Thu, Oct 29, 2015 at 04:02:11PM -0700, Cesar Philippidis wrote: > I noticed that num_gangs, num_workers and vector_length are parsed in > somewhat insistent ways in the c++ FE. Both vector_length and num_gangs > bail out whenever as soon as they detect errors, whereas num_workers > does not.

Re: [OpenACC] num_gangs, num_workers and vector_length in c++

2015-10-30 Thread Cesar Philippidis
On 10/30/2015 06:37 AM, Jakub Jelinek wrote: > On Thu, Oct 29, 2015 at 04:02:11PM -0700, Cesar Philippidis wrote: >> I noticed that num_gangs, num_workers and vector_length are parsed in >> somewhat insistent ways in the c++ FE. Both vector_length and num_gangs >> bail out whenever as soon as they

Re: [OpenACC] num_gangs, num_workers and vector_length in c++

2015-10-30 Thread Jakub Jelinek
On Fri, Oct 30, 2015 at 07:42:39AM -0700, Cesar Philippidis wrote: > The openacc spec doesn't actually define int-expr, but we take to me > mean a single integral value. In general, the openacc spec uses the term > list to describe comma separated expressions. So we've been assuming So does

[OpenACC] num_gangs, num_workers and vector_length in c++

2015-10-29 Thread Cesar Philippidis
603,39 @@ cp_parser_oacc_simple_clause (cp_parser * /* parser */, return c; } + /* OpenACC: + num_gangs ( expression ) + num_workers ( expression ) + vector_length ( expression ) */ + +static tree +cp_parser_oacc_positive_int_clause (cp_parser *parser, omp_clause_code code, +const char *str, tre