@@ -14,7 +14,7 @@ dnl Copyright (c) 2007-2009 Sun Microsystems, Inc. All rights reserved.
14
14
dnl Copyright (c) 2008-2015 Cisco Systems, Inc. All rights reserved.
15
15
dnl Copyright (c) 2012-2017 Los Alamos National Security, LLC. All rights
16
16
dnl reserved.
17
- dnl Copyright (c) 2015-2018 Research Organization for Information Science
17
+ dnl Copyright (c) 2015-2019 Research Organization for Information Science
18
18
dnl and Technology (RIST). All rights reserved.
19
19
dnl $COPYRIGHT $
20
20
dnl
@@ -59,7 +59,11 @@ AC_DEFUN([OPAL_PROG_CC_C11_HELPER],[
59
59
OPAL_CC_HELPER([if $CC $1 supports C11 _Static_assert], [opal_prog_cc_c11_helper__static_assert_available],
60
60
[[# include <stdint.h>]],[[_Static_assert(sizeof(int64_t) == 8, "WTH");]])
61
61
62
- AS_IF([test $opal_prog_cc_c11_helper__Thread_local_available -eq 1 && test $opal_prog_cc_c11_helper_atomic_var_available -eq 1],
62
+ OPAL_CC_HELPER([if $CC $1 supports C11 atomic_fetch_xor_explicit], [opal_prog_cc_c11_helper_atomic_fetch_xor_explicit_available],
63
+ [[# include <stdatomic.h>
64
+ # include <stdint.h>]],[[_Atomic uint32_t a; uint32_t b; atomic_fetch_xor_explicit(&a, b, memory_order_relaxed);]])
65
+
66
+ AS_IF([test $opal_prog_cc_c11_helper__Thread_local_available -eq 1 && test $opal_prog_cc_c11_helper_atomic_var_available -eq 1 && test $opal_prog_cc_c11_helper_atomic_fetch_xor_explicit_available -eq 1],
63
67
[$2 ],
64
68
[$3 ])
65
69
@@ -127,7 +131,7 @@ AC_DEFUN([OPAL_SETUP_CC],[
127
131
AC_REQUIRE([_OPAL_PROG_CC])
128
132
AC_REQUIRE([AM_PROG_CC_C_O])
129
133
130
- OPAL_VAR_SCOPE_PUSH([opal_prog_cc_c11_helper__Thread_local_available opal_prog_cc_c11_helper_atomic_var_available opal_prog_cc_c11_helper__Atomic_available opal_prog_cc_c11_helper__static_assert_available opal_prog_cc_c11_helper__Generic_available opal_prog_cc__thread_available])
134
+ OPAL_VAR_SCOPE_PUSH([opal_prog_cc_c11_helper__Thread_local_available opal_prog_cc_c11_helper_atomic_var_available opal_prog_cc_c11_helper__Atomic_available opal_prog_cc_c11_helper__static_assert_available opal_prog_cc_c11_helper__Generic_available opal_prog_cc__thread_available opal_prog_cc_c11_helper_atomic_fetch_xor_explicit_available ])
131
135
132
136
# AC_PROG_CC_C99 changes CC (instead of CFLAGS) so save CC (without c99
133
137
# flags) for use in our wrappers.
0 commit comments