[Openmp-commits] [PATCH] D52122: [OpenMP][libomptarget] Set the frame pointer then test empty slot condition

Phabricator via Phabricator via Openmp-commits openmp-commits at lists.llvm.org
Tue Sep 25 11:49:45 PDT 2018


This revision was automatically updated to reflect the committed changes.
Closed by commit rOMP343006: [OpenMP][libomptarget] Set the frame pointer then test empty slot condition (authored by gbercea, committed by ).

Repository:
  rL LLVM

https://reviews.llvm.org/D52122

Files:
  libomptarget/deviceRTLs/nvptx/src/data_sharing.cu


Index: libomptarget/deviceRTLs/nvptx/src/data_sharing.cu
===================================================================
--- libomptarget/deviceRTLs/nvptx/src/data_sharing.cu
+++ libomptarget/deviceRTLs/nvptx/src/data_sharing.cu
@@ -477,13 +477,13 @@
     // Pointer to next available stack.
     void *&StackP = DataSharingState.StackPtr[WID];
 
+    // Pop the frame.
+    StackP = FrameStart;
+
     // If the current slot is empty, we need to free the slot after the
     // pop.
     bool SlotEmpty = (StackP == &SlotP->Data[0]);
 
-    // Pop the frame.
-    StackP = FrameStart;
-
     if (SlotEmpty && SlotP->Prev) {
       // Before removing the slot we need to reset StackP.
       StackP = SlotP->PrevSlotStackPtr;


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D52122.166965.patch
Type: text/x-patch
Size: 730 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/openmp-commits/attachments/20180925/70d2ea8d/attachment.bin>


More information about the Openmp-commits mailing list