Index: libomptarget/deviceRTLs/nvptx/src/interface.h =================================================================== --- libomptarget/deviceRTLs/nvptx/src/interface.h +++ libomptarget/deviceRTLs/nvptx/src/interface.h @@ -491,6 +491,9 @@ EXTERN void __kmpc_end_sharing_variables(); EXTERN void __kmpc_get_shared_variables(void ***GlobalArgs); +// SPMD execution mode interrogation function. +EXTERN bool __kmpc_is_spmd_exec_mode(); + // The slot used for data sharing by the master and worker threads. We use a // complete (default size version and an incomplete one so that we allow sizes // greater than the default). Index: libomptarget/deviceRTLs/nvptx/src/omptarget-nvptx.cu =================================================================== --- libomptarget/deviceRTLs/nvptx/src/omptarget-nvptx.cu +++ libomptarget/deviceRTLs/nvptx/src/omptarget-nvptx.cu @@ -187,3 +187,8 @@ omptarget_nvptx_threadPrivateContext); } } + +// Return true if the current target region is executed in SPMD mode. +EXTERN bool __kmpc_is_spmd_exec_mode(){ + return isSPMDMode(); +} \ No newline at end of file