2 /* { dg-options "-O2" } */
3 /* { dg-additional-options "-std=c99" { target c } } */
4 /* { dg-additional-options "-msse2" { target sse2_runtime } } */
5 /* { dg-additional-options "-mavx" { target avx_runtime } } */
10 __attribute__((noipa
)) void
14 #pragma omp taskloop simd reduction (+:m) grainsize (64)
15 for (i
= 0; i
< N
; ++i
)
19 __attribute__((noipa
)) void
22 #pragma omp taskloop simd in_reduction (+:n) grainsize (64) nogroup
23 for (int i
= (x
& 1) * (N
/ 2); i
< (x
& 1) * (N
/ 2) + (N
/ 2); i
++)
31 for (i
= 0; i
< N
; ++i
)
33 #pragma omp parallel master
36 #pragma omp taskgroup task_reduction (+:n)
42 if (m
!= (long)(N
- 1) * (N
/ 2) || n
!= (long)(N
- 1) * N
)