aboutsummaryrefslogtreecommitdiff
path: root/lib/libcxx/src/atomic.cpp
diff options
context:
space:
mode:
authorMichael Dusan <michael.dusan@gmail.com>2021-02-26 16:09:37 -0500
committerAndrew Kelley <andrew@ziglang.org>2021-02-26 13:44:33 -0800
commit659f712ae8a812f9fa64f90af23c9b2b4acabcb0 (patch)
treee4684e271f7188a6c590b6c58dc6eea319236947 /lib/libcxx/src/atomic.cpp
parentb706b9bce798666937b7cafde9d778085cbf4e2f (diff)
downloadzig-659f712ae8a812f9fa64f90af23c9b2b4acabcb0.tar.gz
zig-659f712ae8a812f9fa64f90af23c9b2b4acabcb0.zip
llvm12: sync with llvmorg-12.0.0-rc2
- update lib/include - update lib/libcxx - update lib/libcxxabi - update lib/libunwind - (no changes) src/libcxx.zig - (no changes) src/libunwind.zig
Diffstat (limited to 'lib/libcxx/src/atomic.cpp')
-rw-r--r--lib/libcxx/src/atomic.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/libcxx/src/atomic.cpp b/lib/libcxx/src/atomic.cpp
index 6b73ed771c..9ae1fb5199 100644
--- a/lib/libcxx/src/atomic.cpp
+++ b/lib/libcxx/src/atomic.cpp
@@ -19,6 +19,12 @@
#include <linux/futex.h>
#include <sys/syscall.h>
+// libc++ uses SYS_futex as a universal syscall name. However, on 32 bit architectures
+// with a 64 bit time_t, we need to specify SYS_futex_time64.
+#if !defined(SYS_futex) && defined(SYS_futex_time64)
+# define SYS_futex SYS_futex_time64
+#endif
+
#else // <- Add other operating systems here
// Baseline needs no new headers