[libc][test] Adjust header paths in tests (#119623)
[llvm-project.git] / clang / test / ParserOpenACC / parse-wait-clause.c
blob9c7faa5c02eb35a3d3e665bab356cc96570ff37e
1 // RUN: %clang_cc1 %s -verify -fopenacc
3 void func() {
4 int i, j;
6 #pragma acc parallel wait
7 {}
9 // expected-error@+1{{invalid OpenACC clause 'clause'}}
10 #pragma acc parallel wait clause-list
13 // expected-error@+2{{expected ')'}}
14 // expected-note@+1{{to match this '('}}
15 #pragma acc parallel wait (
18 #pragma acc parallel wait ()
21 // expected-error@+1{{invalid OpenACC clause 'clause'}}
22 #pragma acc parallel wait () clause-list
25 // expected-error@+3{{expected expression}}
26 // expected-error@+2{{expected ')'}}
27 // expected-note@+1{{to match this '('}}
28 #pragma acc parallel wait (devnum:
31 // expected-error@+1{{expected expression}}
32 #pragma acc parallel wait (devnum:)
35 // expected-error@+2{{expected expression}}
36 // expected-error@+1{{invalid OpenACC clause 'clause'}}
37 #pragma acc parallel wait (devnum:) clause-list
40 // expected-error@+3{{expected ':'}}
41 // expected-error@+2{{expected ')'}}
42 // expected-note@+1{{to match this '('}}
43 #pragma acc parallel wait (devnum: i + j
46 // expected-error@+1{{expected ':'}}
47 #pragma acc parallel wait (devnum: i + j)
50 // expected-error@+2{{expected ':'}}
51 // expected-error@+1{{invalid OpenACC clause 'clause'}}
52 #pragma acc parallel wait (devnum: i + j) clause-list
55 // expected-error@+2{{expected ')'}}
56 // expected-note@+1{{to match this '('}}
57 #pragma acc parallel wait (queues:
60 #pragma acc parallel wait (queues:)
63 // expected-error@+1{{invalid OpenACC clause 'clause'}}
64 #pragma acc parallel wait (queues:) clause-list
67 // expected-error@+2{{expected ')'}}
68 // expected-note@+1{{to match this '('}}
69 #pragma acc parallel wait (devnum: i + j:queues:
72 #pragma acc parallel wait (devnum: i + j:queues:)
75 // expected-error@+1{{invalid OpenACC clause 'clause'}}
76 #pragma acc parallel wait (devnum: i + j:queues:) clause-list
79 // expected-error@+4{{use of undeclared identifier 'devnum'}}
80 // expected-error@+3{{expected ','}}
81 // expected-error@+2{{expected ')'}}
82 // expected-note@+1{{to match this '('}}
83 #pragma acc parallel wait (queues:devnum: i + j
86 // expected-error@+2{{expected ','}}
87 // expected-error@+1{{use of undeclared identifier 'devnum'}}
88 #pragma acc parallel wait (queues:devnum: i + j)
91 // expected-error@+3{{expected ','}}
92 // expected-error@+2{{use of undeclared identifier 'devnum'}}
93 // expected-error@+1{{invalid OpenACC clause 'clause'}}
94 #pragma acc parallel wait (queues:devnum: i + j) clause-list
97 // expected-error@+3{{OpenACC clause 'wait' requires expression of integer type ('double' invalid)}}
98 // expected-error@+2{{expected ')'}}
99 // expected-note@+1{{to match this '('}}
100 #pragma acc parallel wait(i, j, 1+1, 3.3
103 // expected-error@+1{{OpenACC clause 'wait' requires expression of integer type ('double' invalid)}}
104 #pragma acc parallel wait(i, j, 1+1, 3.3)
106 // expected-error@+2{{OpenACC clause 'wait' requires expression of integer type ('double' invalid)}}
107 // expected-error@+1{{invalid OpenACC clause 'clause'}}
108 #pragma acc parallel wait(i, j, 1+1, 3.3) clause-list
111 // expected-error@+3{{expected expression}}
112 // expected-error@+2{{expected ')'}}
113 // expected-note@+1{{to match this '('}}
114 #pragma acc parallel wait(,
117 // expected-error@+1{{expected expression}}
118 #pragma acc parallel wait(,)
121 // expected-error@+2{{expected expression}}
122 // expected-error@+1{{invalid OpenACC clause 'clause'}}
123 #pragma acc parallel wait(,) clause-list
126 // expected-error@+3{{OpenACC clause 'wait' requires expression of integer type ('double' invalid)}}
127 // expected-error@+2{{expected ')'}}
128 // expected-note@+1{{to match this '('}}
129 #pragma acc parallel wait(queues:i, j, 1+1, 3.3
132 // expected-error@+4{{OpenACC clause 'wait' requires expression of integer type ('double' invalid)}}
133 // expected-error@+3{{expected expression}}
134 // expected-error@+2{{expected ')'}}
135 // expected-note@+1{{to match this '('}}
136 #pragma acc parallel wait(queues:i, j, 1+1, 3.3,
139 // expected-error@+1{{OpenACC clause 'wait' requires expression of integer type ('double' invalid)}}
140 #pragma acc parallel wait(queues:i, j, 1+1, 3.3)
143 // expected-error@+2{{OpenACC clause 'wait' requires expression of integer type ('double' invalid)}}
144 // expected-error@+1{{invalid OpenACC clause 'clause'}}
145 #pragma acc parallel wait(queues:i, j, 1+1, 3.3) clause-list
148 // expected-error@+3{{OpenACC clause 'wait' requires expression of integer type ('double' invalid)}}
149 // expected-error@+2{{expected ')'}}
150 // expected-note@+1{{to match this '('}}
151 #pragma acc parallel wait(devnum:3:i, j, 1+1, 3.3
153 // expected-error@+1{{OpenACC clause 'wait' requires expression of integer type ('double' invalid)}}
154 #pragma acc parallel wait(devnum:3:i, j, 1+1, 3.3)
156 // expected-error@+2{{OpenACC clause 'wait' requires expression of integer type ('double' invalid)}}
157 // expected-error@+1{{invalid OpenACC clause 'clause'}}
158 #pragma acc parallel wait(devnum:3:i, j, 1+1, 3.3) clause-list
161 // expected-error@+3{{OpenACC clause 'wait' requires expression of integer type ('double' invalid)}}
162 // expected-error@+2{{expected ')'}}
163 // expected-note@+1{{to match this '('}}
164 #pragma acc parallel wait(devnum:3:queues:i, j, 1+1, 3.3
166 // expected-error@+1{{OpenACC clause 'wait' requires expression of integer type ('double' invalid)}}
167 #pragma acc parallel wait(devnum:3:queues:i, j, 1+1, 3.3)
169 // expected-error@+2{{OpenACC clause 'wait' requires expression of integer type ('double' invalid)}}
170 // expected-error@+1{{invalid OpenACC clause 'clause'}}
171 #pragma acc parallel wait(devnum:3:queues:i, j, 1+1, 3.3) clause-list