| 1 |
// { dg-do compile } |
| 2 |
// { dg-options "-fopenmp-simd" } |
| 3 |
|
| 4 |
#pragma omp declare simd linear(a:1 + b) uniform(b) // { dg-error "use of parameter outside function body before .\\). token" } |
| 5 |
int f1 (int a, int b); |
| 6 |
#pragma omp declare simd linear(a:b + 1) uniform(b) // { dg-error "use of parameter outside function body before .\\+. token" } |
| 7 |
int f2 (int a, int b); |
| 8 |
#pragma omp declare simd linear(a:2 * b) uniform(b) // { dg-error "use of parameter outside function body before .\\). token" } |
| 9 |
int f3 (int a, int b); |
| 10 |
#pragma omp declare simd linear(a:b) // { dg-error ".linear. clause step is a parameter .b. not specified in .uniform. clause" } |
| 11 |
int f4 (int a, int b); |
| 12 |
#pragma omp declare simd linear(a:b) linear(b:1) // { dg-error ".linear. clause step is a parameter .b. not specified in .uniform. clause" } |
| 13 |
int f5 (int a, int b); |
| 14 |
#pragma omp declare simd linear(a:5 + 2 * 3) |
| 15 |
int f6 (int a, int b); |
| 16 |
const int c = 5; |
| 17 |
#pragma omp declare simd linear(a:c) |
| 18 |
int f7 (int a, int b); |
| 19 |
#pragma omp declare simd linear(a:2 * c + 1) |
| 20 |
int f8 (int a, int b); |
| 21 |
#pragma omp declare simd linear(a:0.5) // { dg-error "linear step expression must be integral" } |
| 22 |
int f9 (int a, int b); |