1 // RUN: %libomp-compile-and-run
4 // UNSUPPORTED: clang-4, clang-5, clang-6, clang-7, clang-8, clang-9, clang-10
5 // UNSUPPORTED: gcc-4, gcc-5, gcc-6, gcc-7, gcc-8
12 int main(int argc
, char **argv
) {
14 #pragma omp parallel reduction(task, +:a) reduction(task, *:b)
19 for (i
= 1; i
<= 5; ++i
) {
20 #pragma omp task in_reduction(+: a) in_reduction(*: b)
30 fprintf(stderr
, "error: a != 15. Instead a = %d\n", a
);
34 fprintf(stderr
, "error: b != 120. Instead b = %d\n", b
);