testsuite/libgomp.c/pr32468.c

Go to the documentation of this file.
00001 /* PR libgomp/32468 */
00002 /* { dg-do run } */
00003 
00004 #include <omp.h>
00005 #include <stdlib.h>
00006 
00007 int
00008 main (void)
00009 {
00010   int res[2] = { -1, -1 };
00011   omp_set_dynamic (0);
00012   omp_set_num_threads (4);
00013 #pragma omp parallel
00014   {
00015     #pragma omp sections
00016       {
00017     #pragma omp section
00018     res[0] = omp_get_num_threads () != 4;
00019     #pragma omp section
00020     res[1] = omp_get_num_threads () != 4;
00021       }
00022   }
00023   if (res[0] != 0 || res[1] != 0)
00024     abort ();
00025   return 0;
00026 }

Generated on Fri Apr 5 05:38:10 2013 for Libgomp by  doxygen 1.4.7