[Openmp-commits] [openmp] r323978 - [OpenMP-RT] Fix debug string for NVPTX runtime library

Carlo Bertolli via Openmp-commits openmp-commits at lists.llvm.org
Thu Feb 1 08:12:16 PST 2018


Author: cbertol
Date: Thu Feb  1 08:12:16 2018
New Revision: 323978

URL: http://llvm.org/viewvc/llvm-project?rev=323978&view=rev
Log:
[OpenMP-RT] Fix debug string for NVPTX runtime library

https://reviews.llvm.org/D42757

The method ThreadsInTeam is used to determine the number of threads to be used in a parallel region under SPMD mode (see line 127 of supporti.h in libomptarget/deviceRTLs/nvptx/src/). This patch fixes the corresponding debug print upon initialization of the kernel in SPMD mode.


Modified:
    openmp/trunk/libomptarget/deviceRTLs/nvptx/src/omptarget-nvptx.cu

Modified: openmp/trunk/libomptarget/deviceRTLs/nvptx/src/omptarget-nvptx.cu
URL: http://llvm.org/viewvc/llvm-project/openmp/trunk/libomptarget/deviceRTLs/nvptx/src/omptarget-nvptx.cu?rev=323978&r1=323977&r2=323978&view=diff
==============================================================================
--- openmp/trunk/libomptarget/deviceRTLs/nvptx/src/omptarget-nvptx.cu (original)
+++ openmp/trunk/libomptarget/deviceRTLs/nvptx/src/omptarget-nvptx.cu Thu Feb  1 08:12:16 2018
@@ -163,7 +163,7 @@ EXTERN void __kmpc_spmd_kernel_init(int
   PRINT(LD_PAR,
         "thread will execute parallel region with id %d in a team of "
         "%d threads\n",
-        newTaskDescr->ThreadId(), newTaskDescr->NThreads());
+        newTaskDescr->ThreadId(), newTaskDescr->ThreadsInTeam());
 
   if (RequiresDataSharing && threadId % WARPSIZE == 0) {
     // Warp master innitializes data sharing environment.




More information about the Openmp-commits mailing list