1 // RUN: %libomp-compile-and-run
2 // RUN: %libomp-irbuilder-compile-and-run
4 // irbuilder is only available with clang
8 #include "omp_testsuite.h"
10 int test_omp_parallel_if()
19 known_sum
= (LOOPCOUNT
* (LOOPCOUNT
+ 1)) / 2 ;
20 #pragma omp parallel private(i) if(control==0)
23 for (i
= 1; i
<= LOOPCOUNT
; i
++) {
31 return (known_sum
== sum
);
39 for(i
= 0; i
< REPETITIONS
; i
++) {
40 if(!test_omp_parallel_if()) {