[Openmp-commits] [PATCH] D91002: [OpenMP] Fix asm for arm64-darwin
FX Coudert via Phabricator via Openmp-commits
openmp-commits at lists.llvm.org
Sat Nov 7 06:08:01 PST 2020
fxcoudert created this revision.
fxcoudert added reviewers: OpenMP, jdoerfert.
fxcoudert added a project: OpenMP.
Herald added subscribers: openmp-commits, pengfei, guansong, kristof.beyls, yaxunl.
fxcoudert requested review of this revision.
Herald added a subscriber: sstefan1.
Fixes https://bugs.llvm.org/show_bug.cgi?id=47609
Two issues to be fixed, allowing OpenMP to compile and run on Apple Silicon (arm64-darrwin):
- __kmp_unnamed_criticaladdr needs an extra underscore on Darwin
- the .size should be Linux-only
Both fixes are pretty much the same as the existing X86 and X86_64 Darwin code at the top of that same file.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D91002
Files:
openmp/runtime/src/z_Linux_asm.S
Index: openmp/runtime/src/z_Linux_asm.S
===================================================================
--- openmp/runtime/src/z_Linux_asm.S
+++ openmp/runtime/src/z_Linux_asm.S
@@ -1741,10 +1741,12 @@
.comm .gomp_critical_user_,32,8
.data
.align 8
- .global __kmp_unnamed_critical_addr
-__kmp_unnamed_critical_addr:
+ .global KMP_PREFIX_UNDERSCORE(__kmp_unnamed_critical_addr)
+KMP_PREFIX_UNDERSCORE(__kmp_unnamed_critical_addr):
.8byte .gomp_critical_user_
+# if KMP_OS_LINUX
.size __kmp_unnamed_critical_addr,8
+# endif /* KMP_OS_LINUX */
#endif /* KMP_ARCH_PPC64 || KMP_ARCH_AARCH64 || KMP_ARCH_MIPS64 ||
KMP_ARCH_RISCV64 */
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D91002.303637.patch
Type: text/x-patch
Size: 678 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/openmp-commits/attachments/20201107/eae738e4/attachment.bin>
More information about the Openmp-commits
mailing list