[OpenMP][FIX] The thread limit is the block, not grid size
authorJohannes Doerfert <johannes@jdoerfert.de>
Thu, 12 Jan 2023 23:29:55 +0000 (15:29 -0800)
committerJohannes Doerfert <johannes@jdoerfert.de>
Thu, 12 Jan 2023 23:42:32 +0000 (15:42 -0800)
openmp/libomptarget/DeviceRTL/src/State.cpp

index aaf81b9..9c1c9ab 100644 (file)
@@ -357,7 +357,7 @@ int omp_get_num_threads(void) {
   return omp_get_level() > 1 ? 1 : state::ParallelTeamSize;
 }
 
-int omp_get_thread_limit(void) { return mapping::getKernelSize(); }
+int omp_get_thread_limit(void) { return mapping::getBlockSize(); }
 
 int omp_get_num_procs(void) { return mapping::getNumberOfProcessorElements(); }