Debian Codegraph @

gcc/testsuite/g++.dg/modules/omp-1_a.C

raw
1 // { dg-additional-options "-fmodules-ts -fopenmp" }
2 // { dg-require-effective-target pthread }
3
4 export module foo;
5 // { dg-module-cmi foo { target pthread } }
6
7 export inline void frob (unsigned (&ary)[64])
8 {
9 int sum = 0;
10
11 #pragma omp for
12 for (unsigned ix = 0; ix < 64; ix++)
13 sum += ary[ix];
14
15 #pragma omp simd safelen(16) aligned (ary : 16)
16 for (unsigned ix = 0; ix < 64; ix++)
17 ary[ix] *= 2;
18 }