[Openmp-commits] [PATCH] D138737: [openmp] Use GCC style intrinsics for atomics on Clang-cl on aarch64 too
Martin Storsjö via Phabricator via Openmp-commits
openmp-commits at lists.llvm.org
Fri Nov 25 14:56:37 PST 2022
mstorsjo created this revision.
mstorsjo added reviewers: AndreyChurbanov, JonChesterfield, natgla, jdoerfert, Meinersbur, DavidSpickett.
Herald added subscribers: guansong, kristof.beyls, yaxunl.
Herald added a project: All.
mstorsjo requested review of this revision.
Herald added a subscriber: sstefan1.
Herald added a project: OpenMP.
This fixes compilation in the Clang-cl configuration on aarch64;
Clang doesn't implement all the aarch64 MSVC atomic intrinsics yet.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D138737
Files:
openmp/runtime/src/kmp_os.h
Index: openmp/runtime/src/kmp_os.h
===================================================================
--- openmp/runtime/src/kmp_os.h
+++ openmp/runtime/src/kmp_os.h
@@ -456,7 +456,7 @@
// Synchronization primitives
-#if KMP_ASM_INTRINS && KMP_OS_WINDOWS && !((KMP_ARCH_AARCH64 || KMP_ARCH_ARM) && defined(__GNUC__))
+#if KMP_ASM_INTRINS && KMP_OS_WINDOWS && !((KMP_ARCH_AARCH64 || KMP_ARCH_ARM) && (KMP_COMPILER_CLANG || KMP_COMPILER_GCC))
#if KMP_MSVC_COMPAT && !KMP_COMPILER_CLANG
#pragma intrinsic(InterlockedExchangeAdd)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D138737.478028.patch
Type: text/x-patch
Size: 536 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/openmp-commits/attachments/20221125/f2db4635/attachment.bin>
More information about the Openmp-commits
mailing list