1 /* Test large vector lengths. */
8 #define gentest(name, outer, inner) \
11 long i, j, t1, t2, t3; \
13 for (i = 0; i < n; i++) \
18 for (j = i; j < n; j++) \
26 for (i = 0; i < n; i++) \
28 assert (a1[i] == n-i); \
29 assert (a2[i] == -(n-i)); \
33 gentest (test1, "acc parallel loop gang vector_length (128) firstprivate (t1, t2)",
34 "acc loop vector reduction(+:t1) reduction(-:t2)")
36 gentest (test2
, "acc parallel loop gang vector_length (128) firstprivate (t1, t2)",
37 "acc loop worker vector reduction(+:t1) reduction(-:t2)")
39 gentest (test3
, "acc parallel loop gang worker vector_length (128) firstprivate (t1, t2)",
40 "acc loop vector reduction(+:t1) reduction(-:t2)")
42 gentest (test4
, "acc parallel loop firstprivate (t1, t2)",
43 "acc loop reduction(+:t1) reduction(-:t2)")