From 8ce0ee786539ba865367dbe68185ffed0ff700a7 Mon Sep 17 00:00:00 2001 From: midipix Date: May 23 2016 08:20:37 +0000 Subject: nt_atomic.h: i386: implement at_store_64() in terms or at_locked_cas_64. --- diff --git a/include/ntapi/bits/i386/nt_atomic_i386_asm__gcc.h b/include/ntapi/bits/i386/nt_atomic_i386_asm__gcc.h index 1e9ed71..adf000f 100644 --- a/include/ntapi/bits/i386/nt_atomic_i386_asm__gcc.h +++ b/include/ntapi/bits/i386/nt_atomic_i386_asm__gcc.h @@ -468,13 +468,9 @@ static __inline__ void at_store_64( prev = *dst; cmp = prev; - __atomic_compare_exchange_n( - dst, - &cmp, - xchg, - 0, - __ATOMIC_SEQ_CST, - __ATOMIC_SEQ_CST); + prev = at_locked_cas_64( + dst,cmp,xchg); + } while (cmp != prev); }