[Openmp-commits] [PATCH] D121007: [Libomptarget] Work around bug in initialization of libomptarget
Joseph Huber via Phabricator via Openmp-commits
openmp-commits at lists.llvm.org
Fri Mar 4 10:13:48 PST 2022
This revision was automatically updated to reflect the committed changes.
Closed by commit rGe2dcc2218c64: [Libomptarget] Work around bug in initialization of libomptarget (authored by jhuber6).
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D121007/new/
https://reviews.llvm.org/D121007
Files:
openmp/libomptarget/DeviceRTL/src/Mapping.cpp
Index: openmp/libomptarget/DeviceRTL/src/Mapping.cpp
===================================================================
--- openmp/libomptarget/DeviceRTL/src/Mapping.cpp
+++ openmp/libomptarget/DeviceRTL/src/Mapping.cpp
@@ -258,7 +258,10 @@
/// Execution mode
///
///{
-static int SHARED(IsSPMDMode);
+
+// TODO: This is a workaround for initialization coming from kernels outside of
+// the TU. We will need to solve this more correctly in the future.
+int __attribute__((used, retain, weak)) SHARED(IsSPMDMode);
void mapping::init(bool IsSPMD) {
if (mapping::isInitialThreadInLevel0(IsSPMD))
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D121007.413059.patch
Type: text/x-patch
Size: 610 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/openmp-commits/attachments/20220304/5c58b142/attachment.bin>
More information about the Openmp-commits
mailing list