[Openmp-commits] [PATCH] D90974: Fixes for shared memory cleanup when aborts occur

Andrey Churbanov via Phabricator via Openmp-commits openmp-commits at lists.llvm.org
Tue Nov 10 13:16:53 PST 2020


This revision was automatically updated to reflect the committed changes.
Closed by commit rG33da6bd7f503: [OpenMP] Fixes for shared memory cleanup when aborts occur (authored by AndreyChurbanov).

Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D90974/new/

https://reviews.llvm.org/D90974

Files:
  openmp/runtime/src/kmp_runtime.cpp


Index: openmp/runtime/src/kmp_runtime.cpp
===================================================================
--- openmp/runtime/src/kmp_runtime.cpp
+++ openmp/runtime/src/kmp_runtime.cpp
@@ -441,6 +441,7 @@
     raise(SIGABRT);
     _exit(3); // Just in case, if signal ignored, exit anyway.
   } else {
+    __kmp_unregister_library();
     abort();
   }
 
@@ -6170,6 +6171,7 @@
       if (__kmp_root[gtid]->r.r_active) {
         __kmp_global.g.g_abort = -1;
         TCW_SYNC_4(__kmp_global.g.g_done, TRUE);
+        __kmp_unregister_library();
         KA_TRACE(10,
                  ("__kmp_internal_end_library: root still active, abort T#%d\n",
                   gtid));


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D90974.304315.patch
Type: text/x-patch
Size: 680 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/openmp-commits/attachments/20201110/dc6b889e/attachment.bin>


More information about the Openmp-commits mailing list