1 extern "C" void abort ();
3 struct S { S (); S (long long int, int); ~S (); static int cnt1, cnt2, cnt3; long long int s; int t; };
15 S::S (long long int x, int y) : s (x), t (y)
17 #pragma omp atomic update
25 if (t < 3 || t > 9 || (t & 1) == 0)
41 if (o->t != 5 || i->t != 9)
46 #pragma omp declare reduction (+: S : omp_out.s += omp_in.s) initializer (omp_priv (0, 3))
47 #pragma omp declare reduction (*: S : baz (&omp_out, &omp_in)) initializer (bar (&omp_priv, &omp_orig))
58 for (i = 0; i < 2; i++)
59 #pragma omp task in_reduction (+: c) in_reduction (*: b, d) in_reduction (+: a)
65 if ((a.t != 7 && a.t != 3) || (b.t != 5 && b.t != 9)
66 || (c.t != 7 && c.t != 3) || (d.t != 5 && d.t != 9))
81 #pragma omp taskgroup task_reduction (+: a, c) task_reduction (*: b, d)
84 for (i = 0; i < 4; i++)
85 #pragma omp task in_reduction (*: b, d) in_reduction (+: a, c)
90 for (j = 0; j < 2; j++)
91 #pragma omp task in_reduction (+: a) in_reduction (*: b) \
92 in_reduction (+: c) in_reduction (*: d)
99 if ((a.t != 7 && a.t != 3) || (b.t != 5 && b.t != 9)
100 || (c.t != 7 && c.t != 3) || (d.t != 5 && d.t != 9))
105 if ((a.t != 7 && a.t != 3) || (b.t != 5 && b.t != 9)
106 || (c.t != 7 && c.t != 3) || (d.t != 5 && d.t != 9))
110 #define THREEP7 (3LL * 3LL * 3LL * 3LL * 3LL * 3LL * 3LL)
111 if (d.s != (THREEP7 * THREEP7 * THREEP7 * THREEP7) || d.t != 5)
114 if (a.s != 28 * 7 || a.t != 7 || b.s != (1L << 28) || b.t != 5
115 || c.s != 28 * 9 || c.t != 7)
122 int c1 = S::cnt1, c2 = S::cnt2, c3 = S::cnt3;
124 if (S::cnt1 + S::cnt2 - c1 - c2 != S::cnt3 - c3)