Open main menu

CDOT Wiki β

Changes

GPU621/OpenMP Debugging

48 bytes added, 20:06, 8 December 2021
Case A - Using the Thread window
printf("\n");
#pragma omp parallel
{
#pragma omp single // set openMP ver
{
printf("num of thread currently using is %d \n", omp_get_num_threads());
printf("\n");
#pragma omp parallel num_threads(8)
{
#pragma omp single // set openMP with num of threads ver
{
printf("num of thread currently using is %d \n", omp_get_num_threads());
49
edits