diff options
Diffstat (limited to 'gcc-4.9/gcc/testsuite/c-c++-common/cilk-plus/AN/sec_reduce_max_min_ind.c')
-rw-r--r-- | gcc-4.9/gcc/testsuite/c-c++-common/cilk-plus/AN/sec_reduce_max_min_ind.c | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/gcc-4.9/gcc/testsuite/c-c++-common/cilk-plus/AN/sec_reduce_max_min_ind.c b/gcc-4.9/gcc/testsuite/c-c++-common/cilk-plus/AN/sec_reduce_max_min_ind.c new file mode 100644 index 000000000..9652e1594 --- /dev/null +++ b/gcc-4.9/gcc/testsuite/c-c++-common/cilk-plus/AN/sec_reduce_max_min_ind.c @@ -0,0 +1,17 @@ +/* { dg-do compile } */ +/* { dg-options "-fcilkplus" } */ + +int main (void) +{ + int array[10][10], array2[10]; + int x, y; + x = __sec_reduce_max_ind (array[:][:]); /* { dg-error "cannot have arrays with dimension greater than" } */ + + y = __sec_reduce_max_ind (array2[:]); /* this should be OK. */ + + x = __sec_reduce_min_ind (array[:][:]); /* { dg-error "cannot have arrays with dimension greater than" } */ + + y = __sec_reduce_min_ind (array2[:]); /* this should be OK. */ + + return 0; +} |