blob: 1ae2e33b4f573b2e0c2cb93e103f8ef9df9132e5 [file] [log] [blame]
Brad Bishop1a4b7ee2018-12-16 17:11:34 -08001From a237553ccd15276462be2023057a017fa8ee5d7c Mon Sep 17 00:00:00 2001
Patrick Williamsd8c66bc2016-06-20 12:57:21 -05002From: Khem Raj <raj.khem@gmail.com>
3Date: Thu, 31 Dec 2015 14:35:35 -0800
Brad Bishop1a4b7ee2018-12-16 17:11:34 -08004Subject: [PATCH] nativesdk-glibc: Allow 64 bit atomics for x86
Patrick Williamsd8c66bc2016-06-20 12:57:21 -05005
6The fix consist of allowing 64bit atomic ops for x86.
7This should be safe for i586 and newer CPUs.
8It also makes the synchronization more efficient.
9
Brad Bishopd7bf8c12018-02-25 22:55:05 -050010Upstream-Status: Inappropriate [OE-Specific]
11
Patrick Williamsd8c66bc2016-06-20 12:57:21 -050012Signed-off-by: Juro Bystricky <juro.bystricky@intel.com>
13Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
14Signed-off-by: Khem Raj <raj.khem@gmail.com>
15---
16 sysdeps/i386/atomic-machine.h | 2 +-
17 1 file changed, 1 insertion(+), 1 deletion(-)
18
19diff --git a/sysdeps/i386/atomic-machine.h b/sysdeps/i386/atomic-machine.h
Brad Bishop316dfdd2018-06-25 12:45:53 -040020index 272da5dd8f..409c759f14 100644
Patrick Williamsd8c66bc2016-06-20 12:57:21 -050021--- a/sysdeps/i386/atomic-machine.h
22+++ b/sysdeps/i386/atomic-machine.h
23@@ -54,7 +54,7 @@ typedef uintmax_t uatomic_max_t;
24 # endif
25 #endif
26
27-#define __HAVE_64B_ATOMICS 0
28+#define __HAVE_64B_ATOMICS 1
29 #define USE_ATOMIC_COMPILER_BUILTINS 0
Brad Bishopd7bf8c12018-02-25 22:55:05 -050030 #define ATOMIC_EXCHANGE_USES_CAS 0
Patrick Williamsd8c66bc2016-06-20 12:57:21 -050031