diff options
Diffstat (limited to 'gcc-4.9/gcc/testsuite/c-c++-common/gomp/depend-2.c')
-rw-r--r-- | gcc-4.9/gcc/testsuite/c-c++-common/gomp/depend-2.c | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/gcc-4.9/gcc/testsuite/c-c++-common/gomp/depend-2.c b/gcc-4.9/gcc/testsuite/c-c++-common/gomp/depend-2.c new file mode 100644 index 000000000..99bf8ae1b --- /dev/null +++ b/gcc-4.9/gcc/testsuite/c-c++-common/gomp/depend-2.c @@ -0,0 +1,19 @@ +/* { dg-do compile } */ +/* { dg-options "-fopenmp" } */ + +void bar (int a[10][10][10]); +void +foo (int a[10][10][10], int **b) +{ + int c[10][10][10]; + #pragma omp task depend(out: a[2:4][3:][:7], b[1:7][2:8]) + bar (a); + int i = 1, j = 3, k = 2, l = 6; + #pragma omp task depend(in: a[++i:++j][++k:][:++l]) + bar (a); + #pragma omp task depend(out: a[7:2][:][:], c[5:2][:][:]) + { + bar (c); + bar (a); + } +} |