diff options
Diffstat (limited to 'libgomp/testsuite/libgomp.c/omp-single-3.c')
-rw-r--r-- | libgomp/testsuite/libgomp.c/omp-single-3.c | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/libgomp/testsuite/libgomp.c/omp-single-3.c b/libgomp/testsuite/libgomp.c/omp-single-3.c new file mode 100644 index 000000000..5a0653244 --- /dev/null +++ b/libgomp/testsuite/libgomp.c/omp-single-3.c @@ -0,0 +1,21 @@ +extern void abort (void); + +void +single (int a, int b) +{ + #pragma omp single copyprivate(a) copyprivate(b) + { + a = b = 5; + } + + if (a != b) + abort (); +} + +int main() +{ + #pragma omp parallel + single (1, 2); + + return 0; +} |