18#if (AO_GNUC_PREREQ(5, 4) || AO_CLANG_PREREQ(8, 0)) && defined(__s390x__) \
19 && !defined(AO_DISABLE_GCC_ATOMICS)
41#include "../all_aligned_atomic_load_store.h"
43#include "../ordered_except_wr.h"
45#include "../test_and_set_t_is_ao_t.h"
52#ifndef AO_GENERALIZE_ASM_BOOL_CAS
57 __asm__ __volatile__ (
65 :
"=&d" (
retval),
"+d" (old)
66 :
"d" (new_val),
"a" (addr)
70#define AO_HAVE_compare_and_swap_full
77 __asm__ __volatile__ (
83 :
"+d" (old),
"=Q" (*addr)
84 :
"d" (new_val),
"m" (*addr)
88#define AO_HAVE_fetch_compare_and_swap_full
#define AO_fetch_compare_and_swap_full(addr, old, newval)
AO_INLINE int AO_compare_and_swap_full(volatile AO_t *addr, AO_t old, AO_t new_val)