[llvm] [OpenMP][Offload] Add SPMD-No-Loop mode to OpenMP offload runtime (PR #154105)
Dhruva Chakrabarti via llvm-commits
llvm-commits at lists.llvm.org
Fri Aug 22 11:50:18 PDT 2025
================
@@ -640,6 +640,18 @@ uint32_t GenericKernelTy::getNumThreads(GenericDeviceTy &GenericDevice,
if (ThreadLimitClause[0] > 0 && isGenericMode())
ThreadLimitClause[0] += GenericDevice.getWarpSize();
+ // Honor OMP_TEAMS_THREAD_LIMIT environment variable and
+ // num_threads/thread_limit clause for NoLoop kernel types.
+ int32_t TeamsThreadLimitEnvVar = GenericDevice.getOMPTeamsThreadLimit();
+ uint16_t ConstWGSize = GenericDevice.getDefaultNumThreads();
----------------
dhruvachak wrote:
Why not use PreferredNumThreads instead of GenericDevice.getDefaultNumThreads()?
https://github.com/llvm/llvm-project/pull/154105
More information about the llvm-commits
mailing list