32#ifndef _GLIBCXX_ATOMIC
33#define _GLIBCXX_ATOMIC 1
36#pragma GCC system_header
39#if __cplusplus < 201103L
43#define __glibcxx_want_atomic_is_always_lock_free
44#define __glibcxx_want_atomic_flag_test
45#define __glibcxx_want_atomic_float
46#define __glibcxx_want_atomic_min_max
47#define __glibcxx_want_atomic_ref
48#define __glibcxx_want_atomic_lock_free_type_aliases
49#define __glibcxx_want_atomic_value_initialization
50#define __glibcxx_want_atomic_wait
57namespace std _GLIBCXX_VISIBILITY(default)
59_GLIBCXX_BEGIN_NAMESPACE_VERSION
66 template<
typename _Tp>
74 using value_type = bool;
77 __atomic_base<bool> _M_base;
80 atomic() noexcept = default;
81 ~atomic() noexcept = default;
82 atomic(const atomic&) = delete;
83 atomic& operator=(const atomic&) = delete;
84 atomic& operator=(const atomic&) volatile = delete;
86 constexpr atomic(
bool __i) noexcept : _M_base(__i) { }
89 operator=(
bool __i)
noexcept
90 {
return _M_base.operator=(__i); }
93 operator=(
bool __i)
volatile noexcept
94 {
return _M_base.operator=(__i); }
96 operator bool() const noexcept
97 {
return _M_base.load(); }
99 operator bool() const volatile noexcept
100 {
return _M_base.load(); }
103 is_lock_free() const noexcept {
return _M_base.is_lock_free(); }
106 is_lock_free() const volatile noexcept {
return _M_base.is_lock_free(); }
108#ifdef __cpp_lib_atomic_is_always_lock_free
113 store(
bool __i,
memory_order __m = memory_order_seq_cst)
noexcept
114 { _M_base.store(__i, __m); }
117 store(
bool __i,
memory_order __m = memory_order_seq_cst)
volatile noexcept
118 { _M_base.store(__i, __m); }
121 load(
memory_order __m = memory_order_seq_cst)
const noexcept
122 {
return _M_base.load(__m); }
125 load(
memory_order __m = memory_order_seq_cst)
const volatile noexcept
126 {
return _M_base.load(__m); }
129 exchange(
bool __i,
memory_order __m = memory_order_seq_cst)
noexcept
130 {
return _M_base.exchange(__i, __m); }
134 memory_order __m = memory_order_seq_cst)
volatile noexcept
135 {
return _M_base.exchange(__i, __m); }
138 compare_exchange_weak(
bool& __i1,
bool __i2,
memory_order __m1,
140 {
return _M_base.compare_exchange_weak(__i1, __i2, __m1, __m2); }
143 compare_exchange_weak(
bool& __i1,
bool __i2,
memory_order __m1,
145 {
return _M_base.compare_exchange_weak(__i1, __i2, __m1, __m2); }
148 compare_exchange_weak(
bool& __i1,
bool __i2,
150 {
return _M_base.compare_exchange_weak(__i1, __i2, __m); }
153 compare_exchange_weak(
bool& __i1,
bool __i2,
154 memory_order __m = memory_order_seq_cst)
volatile noexcept
155 {
return _M_base.compare_exchange_weak(__i1, __i2, __m); }
158 compare_exchange_strong(
bool& __i1,
bool __i2,
memory_order __m1,
160 {
return _M_base.compare_exchange_strong(__i1, __i2, __m1, __m2); }
163 compare_exchange_strong(
bool& __i1,
bool __i2,
memory_order __m1,
165 {
return _M_base.compare_exchange_strong(__i1, __i2, __m1, __m2); }
168 compare_exchange_strong(
bool& __i1,
bool __i2,
170 {
return _M_base.compare_exchange_strong(__i1, __i2, __m); }
173 compare_exchange_strong(
bool& __i1,
bool __i2,
174 memory_order __m = memory_order_seq_cst)
volatile noexcept
175 {
return _M_base.compare_exchange_strong(__i1, __i2, __m); }
177#if __cpp_lib_atomic_wait
179 wait(
bool __old,
memory_order __m = memory_order_seq_cst)
const noexcept
180 { _M_base.wait(__old, __m); }
185 notify_one() noexcept
186 { _M_base.notify_one(); }
189 notify_all() noexcept
190 { _M_base.notify_all(); }
199 template<
typename _Tp>
202 using value_type = _Tp;
206 static constexpr int _S_min_alignment
207 = (
sizeof(_Tp) & (
sizeof(_Tp) - 1)) ||
sizeof(_Tp) > 16
210 static constexpr int _S_alignment
211 = _S_min_alignment >
alignof(_Tp) ? _S_min_alignment :
alignof(_Tp);
213 alignas(_S_alignment) _Tp _M_i;
215 static_assert(__is_trivially_copyable(_Tp),
216 "std::atomic requires a trivially copyable type");
218 static_assert(
sizeof(_Tp) > 0,
219 "Incomplete or zero-sized types are not supported");
224 "template argument for std::atomic must not be const or volatile");
226#if __cplusplus > 201703L
227 static_assert(is_copy_constructible_v<_Tp>);
228 static_assert(is_move_constructible_v<_Tp>);
229 static_assert(is_copy_assignable_v<_Tp>);
230 static_assert(is_move_assignable_v<_Tp>);
234#if __cpp_lib_atomic_value_initialization
237 constexpr atomic()
noexcept(is_nothrow_default_constructible_v<_Tp>)
238 requires is_default_constructible_v<_Tp>
245 ~atomic()
noexcept =
default;
246 atomic(
const atomic&) =
delete;
247 atomic& operator=(
const atomic&) =
delete;
248 atomic& operator=(
const atomic&)
volatile =
delete;
250 constexpr atomic(_Tp __i) noexcept : _M_i(__i)
252#if __cplusplus >= 201402L && __has_builtin(__builtin_clear_padding)
253 if _GLIBCXX17_CONSTEXPR (__atomic_impl::__maybe_has_padding<_Tp>())
254 if (!std::__is_constant_evaluated())
259 operator _Tp()
const noexcept
262 operator _Tp()
const volatile noexcept
266 operator=(_Tp __i)
noexcept
267 { store(__i);
return __i; }
270 operator=(_Tp __i)
volatile noexcept
271 { store(__i);
return __i; }
274 is_lock_free()
const noexcept
277 return __atomic_is_lock_free(
sizeof(_M_i),
278 reinterpret_cast<void *
>(-_S_alignment));
282 is_lock_free()
const volatile noexcept
285 return __atomic_is_lock_free(
sizeof(_M_i),
286 reinterpret_cast<void *
>(-_S_alignment));
289#ifdef __cpp_lib_atomic_is_always_lock_free
290 static constexpr bool is_always_lock_free
291 = __atomic_always_lock_free(
sizeof(_M_i), 0);
295 store(_Tp __i,
memory_order __m = memory_order_seq_cst)
noexcept
298 __atomic_impl::__clear_padding(__i),
303 store(_Tp __i,
memory_order __m = memory_order_seq_cst)
volatile noexcept
306 __atomic_impl::__clear_padding(__i),
311 load(
memory_order __m = memory_order_seq_cst)
const noexcept
313 alignas(_Tp)
unsigned char __buf[
sizeof(_Tp)];
314 _Tp* __ptr =
reinterpret_cast<_Tp*
>(__buf);
320 load(
memory_order __m = memory_order_seq_cst)
const volatile noexcept
322 alignas(_Tp)
unsigned char __buf[
sizeof(_Tp)];
323 _Tp* __ptr =
reinterpret_cast<_Tp*
>(__buf);
329 exchange(_Tp __i,
memory_order __m = memory_order_seq_cst)
noexcept
331 alignas(_Tp)
unsigned char __buf[
sizeof(_Tp)];
332 _Tp* __ptr =
reinterpret_cast<_Tp*
>(__buf);
334 __atomic_impl::__clear_padding(__i),
341 memory_order __m = memory_order_seq_cst)
volatile noexcept
343 alignas(_Tp)
unsigned char __buf[
sizeof(_Tp)];
344 _Tp* __ptr =
reinterpret_cast<_Tp*
>(__buf);
346 __atomic_impl::__clear_padding(__i),
352 compare_exchange_weak(_Tp& __e, _Tp __i,
memory_order __s,
355 return __atomic_impl::__compare_exchange(_M_i, __e, __i,
true,
360 compare_exchange_weak(_Tp& __e, _Tp __i,
memory_order __s,
363 return __atomic_impl::__compare_exchange(_M_i, __e, __i,
true,
368 compare_exchange_weak(_Tp& __e, _Tp __i,
370 {
return compare_exchange_weak(__e, __i, __m,
371 __cmpexch_failure_order(__m)); }
374 compare_exchange_weak(_Tp& __e, _Tp __i,
375 memory_order __m = memory_order_seq_cst)
volatile noexcept
376 {
return compare_exchange_weak(__e, __i, __m,
377 __cmpexch_failure_order(__m)); }
380 compare_exchange_strong(_Tp& __e, _Tp __i,
memory_order __s,
383 return __atomic_impl::__compare_exchange(_M_i, __e, __i,
false,
388 compare_exchange_strong(_Tp& __e, _Tp __i,
memory_order __s,
391 return __atomic_impl::__compare_exchange(_M_i, __e, __i,
false,
396 compare_exchange_strong(_Tp& __e, _Tp __i,
398 {
return compare_exchange_strong(__e, __i, __m,
399 __cmpexch_failure_order(__m)); }
402 compare_exchange_strong(_Tp& __e, _Tp __i,
403 memory_order __m = memory_order_seq_cst)
volatile noexcept
404 {
return compare_exchange_strong(__e, __i, __m,
405 __cmpexch_failure_order(__m)); }
407#if __cpp_lib_atomic_wait
409 wait(_Tp __old,
memory_order __m = memory_order_seq_cst)
const noexcept
412 [__m,
this] {
return this->load(__m); });
418 notify_one()
noexcept
422 notify_all()
noexcept
428 template<
typename _Tp>
431 using value_type = _Tp*;
432 using difference_type = ptrdiff_t;
434 typedef _Tp* __pointer_type;
435 typedef __atomic_base<_Tp*> __base_type;
438 atomic()
noexcept =
default;
439 ~atomic()
noexcept =
default;
440 atomic(
const atomic&) =
delete;
441 atomic& operator=(
const atomic&) =
delete;
442 atomic& operator=(
const atomic&)
volatile =
delete;
444 constexpr atomic(__pointer_type __p) noexcept : _M_b(__p) { }
446 operator __pointer_type()
const noexcept
447 {
return __pointer_type(_M_b); }
449 operator __pointer_type()
const volatile noexcept
450 {
return __pointer_type(_M_b); }
453 operator=(__pointer_type __p)
noexcept
454 {
return _M_b.operator=(__p); }
457 operator=(__pointer_type __p)
volatile noexcept
458 {
return _M_b.operator=(__p); }
461 operator++(
int)
noexcept
463#if __cplusplus >= 201703L
464 static_assert( is_object_v<_Tp>,
"pointer to object type" );
470 operator++(
int)
volatile noexcept
472#if __cplusplus >= 201703L
473 static_assert( is_object_v<_Tp>,
"pointer to object type" );
479 operator--(
int)
noexcept
481#if __cplusplus >= 201703L
482 static_assert( is_object_v<_Tp>,
"pointer to object type" );
488 operator--(
int)
volatile noexcept
490#if __cplusplus >= 201703L
491 static_assert( is_object_v<_Tp>,
"pointer to object type" );
497 operator++()
noexcept
499#if __cplusplus >= 201703L
500 static_assert( is_object_v<_Tp>,
"pointer to object type" );
506 operator++()
volatile noexcept
508#if __cplusplus >= 201703L
509 static_assert( is_object_v<_Tp>,
"pointer to object type" );
515 operator--()
noexcept
517#if __cplusplus >= 201703L
518 static_assert( is_object_v<_Tp>,
"pointer to object type" );
524 operator--()
volatile noexcept
526#if __cplusplus >= 201703L
527 static_assert( is_object_v<_Tp>,
"pointer to object type" );
533 operator+=(ptrdiff_t __d)
noexcept
535#if __cplusplus >= 201703L
536 static_assert( is_object_v<_Tp>,
"pointer to object type" );
538 return _M_b.operator+=(__d);
542 operator+=(ptrdiff_t __d)
volatile noexcept
544#if __cplusplus >= 201703L
545 static_assert( is_object_v<_Tp>,
"pointer to object type" );
547 return _M_b.operator+=(__d);
551 operator-=(ptrdiff_t __d)
noexcept
553#if __cplusplus >= 201703L
554 static_assert( is_object_v<_Tp>,
"pointer to object type" );
556 return _M_b.operator-=(__d);
560 operator-=(ptrdiff_t __d)
volatile noexcept
562#if __cplusplus >= 201703L
563 static_assert( is_object_v<_Tp>,
"pointer to object type" );
565 return _M_b.operator-=(__d);
569 is_lock_free()
const noexcept
570 {
return _M_b.is_lock_free(); }
573 is_lock_free()
const volatile noexcept
574 {
return _M_b.is_lock_free(); }
576#ifdef __cpp_lib_atomic_is_always_lock_free
577 static constexpr bool is_always_lock_free
578 = ATOMIC_POINTER_LOCK_FREE == 2;
582 store(__pointer_type __p,
584 {
return _M_b.store(__p, __m); }
587 store(__pointer_type __p,
588 memory_order __m = memory_order_seq_cst)
volatile noexcept
589 {
return _M_b.store(__p, __m); }
592 load(
memory_order __m = memory_order_seq_cst)
const noexcept
593 {
return _M_b.load(__m); }
596 load(
memory_order __m = memory_order_seq_cst)
const volatile noexcept
597 {
return _M_b.load(__m); }
600 exchange(__pointer_type __p,
602 {
return _M_b.exchange(__p, __m); }
605 exchange(__pointer_type __p,
606 memory_order __m = memory_order_seq_cst)
volatile noexcept
607 {
return _M_b.exchange(__p, __m); }
610 compare_exchange_weak(__pointer_type& __p1, __pointer_type __p2,
612 {
return _M_b.compare_exchange_weak(__p1, __p2, __m1, __m2); }
615 compare_exchange_weak(__pointer_type& __p1, __pointer_type __p2,
618 {
return _M_b.compare_exchange_weak(__p1, __p2, __m1, __m2); }
621 compare_exchange_weak(__pointer_type& __p1, __pointer_type __p2,
624 return compare_exchange_weak(__p1, __p2, __m,
625 __cmpexch_failure_order(__m));
629 compare_exchange_weak(__pointer_type& __p1, __pointer_type __p2,
630 memory_order __m = memory_order_seq_cst)
volatile noexcept
632 return compare_exchange_weak(__p1, __p2, __m,
633 __cmpexch_failure_order(__m));
637 compare_exchange_strong(__pointer_type& __p1, __pointer_type __p2,
639 {
return _M_b.compare_exchange_strong(__p1, __p2, __m1, __m2); }
642 compare_exchange_strong(__pointer_type& __p1, __pointer_type __p2,
645 {
return _M_b.compare_exchange_strong(__p1, __p2, __m1, __m2); }
648 compare_exchange_strong(__pointer_type& __p1, __pointer_type __p2,
651 return _M_b.compare_exchange_strong(__p1, __p2, __m,
652 __cmpexch_failure_order(__m));
656 compare_exchange_strong(__pointer_type& __p1, __pointer_type __p2,
657 memory_order __m = memory_order_seq_cst)
volatile noexcept
659 return _M_b.compare_exchange_strong(__p1, __p2, __m,
660 __cmpexch_failure_order(__m));
663#if __cpp_lib_atomic_wait
665 wait(__pointer_type __old,
memory_order __m = memory_order_seq_cst)
const noexcept
666 { _M_b.wait(__old, __m); }
671 notify_one()
noexcept
672 { _M_b.notify_one(); }
675 notify_all()
noexcept
676 { _M_b.notify_all(); }
680 fetch_add(ptrdiff_t __d,
683#if __cplusplus >= 201703L
684 static_assert( is_object_v<_Tp>,
"pointer to object type" );
686 return _M_b.fetch_add(__d, __m);
690 fetch_add(ptrdiff_t __d,
691 memory_order __m = memory_order_seq_cst)
volatile noexcept
693#if __cplusplus >= 201703L
694 static_assert( is_object_v<_Tp>,
"pointer to object type" );
696 return _M_b.fetch_add(__d, __m);
700 fetch_sub(ptrdiff_t __d,
703#if __cplusplus >= 201703L
704 static_assert( is_object_v<_Tp>,
"pointer to object type" );
706 return _M_b.fetch_sub(__d, __m);
710 fetch_sub(ptrdiff_t __d,
711 memory_order __m = memory_order_seq_cst)
volatile noexcept
713#if __cplusplus >= 201703L
714 static_assert( is_object_v<_Tp>,
"pointer to object type" );
716 return _M_b.fetch_sub(__d, __m);
723 struct atomic<char> : __atomic_base<char>
725 typedef char __integral_type;
726 typedef __atomic_base<char> __base_type;
728 atomic() noexcept = default;
729 ~
atomic() noexcept = default;
734 constexpr
atomic(__integral_type __i) noexcept : __base_type(__i) { }
736 using __base_type::operator __integral_type;
737 using __base_type::operator=;
739#ifdef __cpp_lib_atomic_is_always_lock_free
740 static constexpr bool is_always_lock_free = ATOMIC_CHAR_LOCK_FREE == 2;
746 struct atomic<signed char> : __atomic_base<signed char>
748 typedef signed char __integral_type;
749 typedef __atomic_base<signed char> __base_type;
751 atomic() noexcept= default;
752 ~atomic() noexcept = default;
753 atomic(const atomic&) = delete;
754 atomic& operator=(const atomic&) = delete;
755 atomic& operator=(const atomic&) volatile = delete;
757 constexpr atomic(__integral_type __i) noexcept : __base_type(__i) { }
759 using __base_type::operator __integral_type;
760 using __base_type::operator=;
762#ifdef __cpp_lib_atomic_is_always_lock_free
763 static constexpr bool is_always_lock_free = ATOMIC_CHAR_LOCK_FREE == 2;
769 struct atomic<unsigned char> : __atomic_base<unsigned char>
771 typedef unsigned char __integral_type;
772 typedef __atomic_base<unsigned char> __base_type;
774 atomic() noexcept= default;
775 ~atomic() noexcept = default;
776 atomic(const atomic&) = delete;
777 atomic& operator=(const atomic&) = delete;
778 atomic& operator=(const atomic&) volatile = delete;
780 constexpr atomic(__integral_type __i) noexcept : __base_type(__i) { }
782 using __base_type::operator __integral_type;
783 using __base_type::operator=;
785#ifdef __cpp_lib_atomic_is_always_lock_free
786 static constexpr bool is_always_lock_free = ATOMIC_CHAR_LOCK_FREE == 2;
792 struct atomic<short> : __atomic_base<short>
794 typedef short __integral_type;
795 typedef __atomic_base<short> __base_type;
797 atomic() noexcept = default;
798 ~atomic() noexcept = default;
799 atomic(const atomic&) = delete;
800 atomic& operator=(const atomic&) = delete;
801 atomic& operator=(const atomic&) volatile = delete;
803 constexpr atomic(__integral_type __i) noexcept : __base_type(__i) { }
805 using __base_type::operator __integral_type;
806 using __base_type::operator=;
808#ifdef __cpp_lib_atomic_is_always_lock_free
809 static constexpr bool is_always_lock_free = ATOMIC_SHORT_LOCK_FREE == 2;
815 struct atomic<unsigned short> : __atomic_base<unsigned short>
817 typedef unsigned short __integral_type;
818 typedef __atomic_base<unsigned short> __base_type;
820 atomic() noexcept = default;
821 ~atomic() noexcept = default;
822 atomic(const atomic&) = delete;
823 atomic& operator=(const atomic&) = delete;
824 atomic& operator=(const atomic&) volatile = delete;
826 constexpr atomic(__integral_type __i) noexcept : __base_type(__i) { }
828 using __base_type::operator __integral_type;
829 using __base_type::operator=;
831#ifdef __cpp_lib_atomic_is_always_lock_free
832 static constexpr bool is_always_lock_free = ATOMIC_SHORT_LOCK_FREE == 2;
838 struct atomic<int> : __atomic_base<int>
840 typedef int __integral_type;
841 typedef __atomic_base<int> __base_type;
843 atomic() noexcept = default;
844 ~atomic() noexcept = default;
845 atomic(const atomic&) = delete;
846 atomic& operator=(const atomic&) = delete;
847 atomic& operator=(const atomic&) volatile = delete;
849 constexpr atomic(__integral_type __i) noexcept : __base_type(__i) { }
851 using __base_type::operator __integral_type;
852 using __base_type::operator=;
854#ifdef __cpp_lib_atomic_is_always_lock_free
855 static constexpr bool is_always_lock_free = ATOMIC_INT_LOCK_FREE == 2;
861 struct atomic<unsigned int> : __atomic_base<unsigned int>
863 typedef unsigned int __integral_type;
864 typedef __atomic_base<unsigned int> __base_type;
866 atomic() noexcept = default;
867 ~atomic() noexcept = default;
868 atomic(const atomic&) = delete;
869 atomic& operator=(const atomic&) = delete;
870 atomic& operator=(const atomic&) volatile = delete;
872 constexpr atomic(__integral_type __i) noexcept : __base_type(__i) { }
874 using __base_type::operator __integral_type;
875 using __base_type::operator=;
877#ifdef __cpp_lib_atomic_is_always_lock_free
878 static constexpr bool is_always_lock_free = ATOMIC_INT_LOCK_FREE == 2;
884 struct atomic<long> : __atomic_base<long>
886 typedef long __integral_type;
887 typedef __atomic_base<long> __base_type;
889 atomic() noexcept = default;
890 ~atomic() noexcept = default;
891 atomic(const atomic&) = delete;
892 atomic& operator=(const atomic&) = delete;
893 atomic& operator=(const atomic&) volatile = delete;
895 constexpr atomic(__integral_type __i) noexcept : __base_type(__i) { }
897 using __base_type::operator __integral_type;
898 using __base_type::operator=;
900#ifdef __cpp_lib_atomic_is_always_lock_free
901 static constexpr bool is_always_lock_free = ATOMIC_LONG_LOCK_FREE == 2;
907 struct atomic<unsigned long> : __atomic_base<unsigned long>
909 typedef unsigned long __integral_type;
910 typedef __atomic_base<unsigned long> __base_type;
912 atomic() noexcept = default;
913 ~atomic() noexcept = default;
914 atomic(const atomic&) = delete;
915 atomic& operator=(const atomic&) = delete;
916 atomic& operator=(const atomic&) volatile = delete;
918 constexpr atomic(__integral_type __i) noexcept : __base_type(__i) { }
920 using __base_type::operator __integral_type;
921 using __base_type::operator=;
923#ifdef __cpp_lib_atomic_is_always_lock_free
924 static constexpr bool is_always_lock_free = ATOMIC_LONG_LOCK_FREE == 2;
930 struct atomic<long long> : __atomic_base<long long>
932 typedef long long __integral_type;
933 typedef __atomic_base<long long> __base_type;
935 atomic() noexcept = default;
936 ~atomic() noexcept = default;
937 atomic(const atomic&) = delete;
938 atomic& operator=(const atomic&) = delete;
939 atomic& operator=(const atomic&) volatile = delete;
941 constexpr atomic(__integral_type __i) noexcept : __base_type(__i) { }
943 using __base_type::operator __integral_type;
944 using __base_type::operator=;
946#ifdef __cpp_lib_atomic_is_always_lock_free
947 static constexpr bool is_always_lock_free = ATOMIC_LLONG_LOCK_FREE == 2;
953 struct atomic<unsigned long long> : __atomic_base<unsigned long long>
955 typedef unsigned long long __integral_type;
956 typedef __atomic_base<unsigned long long> __base_type;
958 atomic() noexcept = default;
959 ~atomic() noexcept = default;
960 atomic(const atomic&) = delete;
961 atomic& operator=(const atomic&) = delete;
962 atomic& operator=(const atomic&) volatile = delete;
964 constexpr atomic(__integral_type __i) noexcept : __base_type(__i) { }
966 using __base_type::operator __integral_type;
967 using __base_type::operator=;
969#ifdef __cpp_lib_atomic_is_always_lock_free
970 static constexpr bool is_always_lock_free = ATOMIC_LLONG_LOCK_FREE == 2;
976 struct atomic<wchar_t> : __atomic_base<wchar_t>
978 typedef wchar_t __integral_type;
979 typedef __atomic_base<wchar_t> __base_type;
981 atomic() noexcept = default;
982 ~atomic() noexcept = default;
983 atomic(const atomic&) = delete;
984 atomic& operator=(const atomic&) = delete;
985 atomic& operator=(const atomic&) volatile = delete;
987 constexpr atomic(__integral_type __i) noexcept : __base_type(__i) { }
989 using __base_type::operator __integral_type;
990 using __base_type::operator=;
992#ifdef __cpp_lib_atomic_is_always_lock_free
993 static constexpr bool is_always_lock_free = ATOMIC_WCHAR_T_LOCK_FREE == 2;
997#ifdef _GLIBCXX_USE_CHAR8_T
1000 struct atomic<char8_t> : __atomic_base<char8_t>
1002 typedef char8_t __integral_type;
1003 typedef __atomic_base<char8_t> __base_type;
1005 atomic() noexcept = default;
1006 ~atomic() noexcept = default;
1007 atomic(const atomic&) = delete;
1008 atomic& operator=(const atomic&) = delete;
1009 atomic& operator=(const atomic&) volatile = delete;
1011 constexpr atomic(__integral_type __i) noexcept : __base_type(__i) { }
1013 using __base_type::operator __integral_type;
1014 using __base_type::operator=;
1016#ifdef __cpp_lib_atomic_is_always_lock_free
1017 static constexpr bool is_always_lock_free
1018 = ATOMIC_CHAR8_T_LOCK_FREE == 2;
1025 struct atomic<char16_t> : __atomic_base<char16_t>
1027 typedef char16_t __integral_type;
1028 typedef __atomic_base<char16_t> __base_type;
1030 atomic() noexcept = default;
1031 ~atomic() noexcept = default;
1032 atomic(const atomic&) = delete;
1033 atomic& operator=(const atomic&) = delete;
1034 atomic& operator=(const atomic&) volatile = delete;
1036 constexpr atomic(__integral_type __i) noexcept : __base_type(__i) { }
1038 using __base_type::operator __integral_type;
1039 using __base_type::operator=;
1041#ifdef __cpp_lib_atomic_is_always_lock_free
1042 static constexpr bool is_always_lock_free
1043 = ATOMIC_CHAR16_T_LOCK_FREE == 2;
1049 struct atomic<char32_t> : __atomic_base<char32_t>
1051 typedef char32_t __integral_type;
1052 typedef __atomic_base<char32_t> __base_type;
1054 atomic() noexcept = default;
1055 ~atomic() noexcept = default;
1056 atomic(const atomic&) = delete;
1057 atomic& operator=(const atomic&) = delete;
1058 atomic& operator=(const atomic&) volatile = delete;
1060 constexpr atomic(__integral_type __i) noexcept : __base_type(__i) { }
1062 using __base_type::operator __integral_type;
1063 using __base_type::operator=;
1065#ifdef __cpp_lib_atomic_is_always_lock_free
1066 static constexpr bool is_always_lock_free
1067 = ATOMIC_CHAR32_T_LOCK_FREE == 2;
1111#ifdef _GLIBCXX_USE_CHAR8_T
1122#ifdef _GLIBCXX_USE_C99_STDINT
1221 atomic_flag_test_and_set_explicit(
atomic_flag* __a,
1223 {
return __a->test_and_set(__m); }
1226 atomic_flag_test_and_set_explicit(
volatile atomic_flag* __a,
1228 {
return __a->test_and_set(__m); }
1230#if __cpp_lib_atomic_flag_test
1233 {
return __a->test(); }
1236 atomic_flag_test(
const volatile atomic_flag* __a)
noexcept
1237 {
return __a->test(); }
1242 {
return __a->test(__m); }
1245 atomic_flag_test_explicit(
const volatile atomic_flag* __a,
1247 {
return __a->test(__m); }
1252 { __a->clear(__m); }
1255 atomic_flag_clear_explicit(
volatile atomic_flag* __a,
1257 { __a->clear(__m); }
1260 atomic_flag_test_and_set(
atomic_flag* __a)
noexcept
1261 {
return atomic_flag_test_and_set_explicit(__a, memory_order_seq_cst); }
1264 atomic_flag_test_and_set(
volatile atomic_flag* __a)
noexcept
1265 {
return atomic_flag_test_and_set_explicit(__a, memory_order_seq_cst); }
1269 { atomic_flag_clear_explicit(__a, memory_order_seq_cst); }
1272 atomic_flag_clear(
volatile atomic_flag* __a)
noexcept
1273 { atomic_flag_clear_explicit(__a, memory_order_seq_cst); }
1275#if __cpp_lib_atomic_wait
1277 atomic_flag_wait(
atomic_flag* __a,
bool __old)
noexcept
1278 { __a->wait(__old); }
1281 atomic_flag_wait_explicit(
atomic_flag* __a,
bool __old,
1283 { __a->wait(__old, __m); }
1287 { __a->notify_one(); }
1291 { __a->notify_all(); }
1297 template<
typename _Tp>
1298 using __atomic_val_t = __type_identity_t<_Tp>;
1299 template<
typename _Tp>
1305 template<
typename _ITp>
1308 {
return __a->is_lock_free(); }
1310 template<
typename _ITp>
1312 atomic_is_lock_free(
const volatile atomic<_ITp>* __a)
noexcept
1313 {
return __a->is_lock_free(); }
1315 template<
typename _ITp>
1317 atomic_init(
atomic<_ITp>* __a, __atomic_val_t<_ITp> __i)
noexcept
1318 { __a->store(__i, memory_order_relaxed); }
1320 template<
typename _ITp>
1322 atomic_init(
volatile atomic<_ITp>* __a, __atomic_val_t<_ITp> __i)
noexcept
1323 { __a->store(__i, memory_order_relaxed); }
1325 template<
typename _ITp>
1327 atomic_store_explicit(
atomic<_ITp>* __a, __atomic_val_t<_ITp> __i,
1329 { __a->store(__i, __m); }
1331 template<
typename _ITp>
1333 atomic_store_explicit(
volatile atomic<_ITp>* __a, __atomic_val_t<_ITp> __i,
1335 { __a->store(__i, __m); }
1337 template<
typename _ITp>
1340 {
return __a->load(__m); }
1342 template<
typename _ITp>
1346 {
return __a->load(__m); }
1348 template<
typename _ITp>
1350 atomic_exchange_explicit(
atomic<_ITp>* __a, __atomic_val_t<_ITp> __i,
1352 {
return __a->exchange(__i, __m); }
1354 template<
typename _ITp>
1357 __atomic_val_t<_ITp> __i,
1359 {
return __a->exchange(__i, __m); }
1361 template<
typename _ITp>
1363 atomic_compare_exchange_weak_explicit(
atomic<_ITp>* __a,
1364 __atomic_val_t<_ITp>* __i1,
1365 __atomic_val_t<_ITp> __i2,
1368 {
return __a->compare_exchange_weak(*__i1, __i2, __m1, __m2); }
1370 template<
typename _ITp>
1372 atomic_compare_exchange_weak_explicit(
volatile atomic<_ITp>* __a,
1373 __atomic_val_t<_ITp>* __i1,
1374 __atomic_val_t<_ITp> __i2,
1377 {
return __a->compare_exchange_weak(*__i1, __i2, __m1, __m2); }
1379 template<
typename _ITp>
1381 atomic_compare_exchange_strong_explicit(
atomic<_ITp>* __a,
1382 __atomic_val_t<_ITp>* __i1,
1383 __atomic_val_t<_ITp> __i2,
1386 {
return __a->compare_exchange_strong(*__i1, __i2, __m1, __m2); }
1388 template<
typename _ITp>
1390 atomic_compare_exchange_strong_explicit(
volatile atomic<_ITp>* __a,
1391 __atomic_val_t<_ITp>* __i1,
1392 __atomic_val_t<_ITp> __i2,
1395 {
return __a->compare_exchange_strong(*__i1, __i2, __m1, __m2); }
1398 template<
typename _ITp>
1400 atomic_store(
atomic<_ITp>* __a, __atomic_val_t<_ITp> __i)
noexcept
1401 { atomic_store_explicit(__a, __i, memory_order_seq_cst); }
1403 template<
typename _ITp>
1405 atomic_store(
volatile atomic<_ITp>* __a, __atomic_val_t<_ITp> __i)
noexcept
1406 { atomic_store_explicit(__a, __i, memory_order_seq_cst); }
1408 template<
typename _ITp>
1411 {
return atomic_load_explicit(__a, memory_order_seq_cst); }
1413 template<
typename _ITp>
1416 {
return atomic_load_explicit(__a, memory_order_seq_cst); }
1418 template<
typename _ITp>
1420 atomic_exchange(
atomic<_ITp>* __a, __atomic_val_t<_ITp> __i)
noexcept
1421 {
return atomic_exchange_explicit(__a, __i, memory_order_seq_cst); }
1423 template<
typename _ITp>
1426 __atomic_val_t<_ITp> __i)
noexcept
1427 {
return atomic_exchange_explicit(__a, __i, memory_order_seq_cst); }
1429 template<
typename _ITp>
1432 __atomic_val_t<_ITp>* __i1,
1433 __atomic_val_t<_ITp> __i2)
noexcept
1435 return atomic_compare_exchange_weak_explicit(__a, __i1, __i2,
1436 memory_order_seq_cst,
1437 memory_order_seq_cst);
1440 template<
typename _ITp>
1442 atomic_compare_exchange_weak(
volatile atomic<_ITp>* __a,
1443 __atomic_val_t<_ITp>* __i1,
1444 __atomic_val_t<_ITp> __i2)
noexcept
1446 return atomic_compare_exchange_weak_explicit(__a, __i1, __i2,
1447 memory_order_seq_cst,
1448 memory_order_seq_cst);
1451 template<
typename _ITp>
1454 __atomic_val_t<_ITp>* __i1,
1455 __atomic_val_t<_ITp> __i2)
noexcept
1457 return atomic_compare_exchange_strong_explicit(__a, __i1, __i2,
1458 memory_order_seq_cst,
1459 memory_order_seq_cst);
1462 template<
typename _ITp>
1464 atomic_compare_exchange_strong(
volatile atomic<_ITp>* __a,
1465 __atomic_val_t<_ITp>* __i1,
1466 __atomic_val_t<_ITp> __i2)
noexcept
1468 return atomic_compare_exchange_strong_explicit(__a, __i1, __i2,
1469 memory_order_seq_cst,
1470 memory_order_seq_cst);
1474#if __cpp_lib_atomic_wait
1475 template<
typename _Tp>
1478 typename std::atomic<_Tp>::value_type __old)
noexcept
1479 { __a->wait(__old); }
1481 template<
typename _Tp>
1484 typename std::atomic<_Tp>::value_type __old,
1486 { __a->wait(__old, __m); }
1488 template<
typename _Tp>
1491 { __a->notify_one(); }
1493 template<
typename _Tp>
1496 { __a->notify_all(); }
1503 template<
typename _ITp>
1506 __atomic_diff_t<_ITp> __i,
1508 {
return __a->fetch_add(__i, __m); }
1510 template<
typename _ITp>
1513 __atomic_diff_t<_ITp> __i,
1515 {
return __a->fetch_add(__i, __m); }
1517 template<
typename _ITp>
1520 __atomic_diff_t<_ITp> __i,
1522 {
return __a->fetch_sub(__i, __m); }
1524 template<
typename _ITp>
1527 __atomic_diff_t<_ITp> __i,
1529 {
return __a->fetch_sub(__i, __m); }
1531 template<
typename _ITp>
1533 atomic_fetch_and_explicit(__atomic_base<_ITp>* __a,
1534 __atomic_val_t<_ITp> __i,
1536 {
return __a->fetch_and(__i, __m); }
1538 template<
typename _ITp>
1540 atomic_fetch_and_explicit(
volatile __atomic_base<_ITp>* __a,
1541 __atomic_val_t<_ITp> __i,
1543 {
return __a->fetch_and(__i, __m); }
1545 template<
typename _ITp>
1547 atomic_fetch_or_explicit(__atomic_base<_ITp>* __a,
1548 __atomic_val_t<_ITp> __i,
1550 {
return __a->fetch_or(__i, __m); }
1552 template<
typename _ITp>
1554 atomic_fetch_or_explicit(
volatile __atomic_base<_ITp>* __a,
1555 __atomic_val_t<_ITp> __i,
1557 {
return __a->fetch_or(__i, __m); }
1559 template<
typename _ITp>
1561 atomic_fetch_xor_explicit(__atomic_base<_ITp>* __a,
1562 __atomic_val_t<_ITp> __i,
1564 {
return __a->fetch_xor(__i, __m); }
1566 template<
typename _ITp>
1568 atomic_fetch_xor_explicit(
volatile __atomic_base<_ITp>* __a,
1569 __atomic_val_t<_ITp> __i,
1571 {
return __a->fetch_xor(__i, __m); }
1573#ifdef __cpp_lib_atomic_min_max
1574 template<
typename _ITp>
1576 atomic_fetch_min_explicit(__atomic_base<_ITp>* __a,
1577 __atomic_val_t<_ITp> __i,
1579 {
return __a->fetch_min(__i, __m); }
1581 template<
typename _ITp>
1583 atomic_fetch_min_explicit(
volatile __atomic_base<_ITp>* __a,
1584 __atomic_val_t<_ITp> __i,
1586 {
return __a->fetch_min(__i, __m); }
1588 template<
typename _ITp>
1590 atomic_fetch_max_explicit(__atomic_base<_ITp>* __a,
1591 __atomic_val_t<_ITp> __i,
1593 {
return __a->fetch_max(__i, __m); }
1595 template<
typename _ITp>
1597 atomic_fetch_max_explicit(
volatile __atomic_base<_ITp>* __a,
1598 __atomic_val_t<_ITp> __i,
1600 {
return __a->fetch_max(__i, __m); }
1603 template<
typename _ITp>
1606 __atomic_diff_t<_ITp> __i)
noexcept
1607 {
return atomic_fetch_add_explicit(__a, __i, memory_order_seq_cst); }
1609 template<
typename _ITp>
1612 __atomic_diff_t<_ITp> __i)
noexcept
1613 {
return atomic_fetch_add_explicit(__a, __i, memory_order_seq_cst); }
1615 template<
typename _ITp>
1618 __atomic_diff_t<_ITp> __i)
noexcept
1619 {
return atomic_fetch_sub_explicit(__a, __i, memory_order_seq_cst); }
1621 template<
typename _ITp>
1624 __atomic_diff_t<_ITp> __i)
noexcept
1625 {
return atomic_fetch_sub_explicit(__a, __i, memory_order_seq_cst); }
1627 template<
typename _ITp>
1629 atomic_fetch_and(__atomic_base<_ITp>* __a,
1630 __atomic_val_t<_ITp> __i)
noexcept
1631 {
return atomic_fetch_and_explicit(__a, __i, memory_order_seq_cst); }
1633 template<
typename _ITp>
1635 atomic_fetch_and(
volatile __atomic_base<_ITp>* __a,
1636 __atomic_val_t<_ITp> __i)
noexcept
1637 {
return atomic_fetch_and_explicit(__a, __i, memory_order_seq_cst); }
1639 template<
typename _ITp>
1641 atomic_fetch_or(__atomic_base<_ITp>* __a,
1642 __atomic_val_t<_ITp> __i)
noexcept
1643 {
return atomic_fetch_or_explicit(__a, __i, memory_order_seq_cst); }
1645 template<
typename _ITp>
1647 atomic_fetch_or(
volatile __atomic_base<_ITp>* __a,
1648 __atomic_val_t<_ITp> __i)
noexcept
1649 {
return atomic_fetch_or_explicit(__a, __i, memory_order_seq_cst); }
1651 template<
typename _ITp>
1653 atomic_fetch_xor(__atomic_base<_ITp>* __a,
1654 __atomic_val_t<_ITp> __i)
noexcept
1655 {
return atomic_fetch_xor_explicit(__a, __i, memory_order_seq_cst); }
1657 template<
typename _ITp>
1659 atomic_fetch_xor(
volatile __atomic_base<_ITp>* __a,
1660 __atomic_val_t<_ITp> __i)
noexcept
1661 {
return atomic_fetch_xor_explicit(__a, __i, memory_order_seq_cst); }
1663#ifdef __cpp_lib_atomic_min_max
1664 template<
typename _ITp>
1666 atomic_fetch_min(__atomic_base<_ITp>* __a,
1667 __atomic_val_t<_ITp> __i)
noexcept
1668 {
return atomic_fetch_min_explicit(__a, __i, memory_order_seq_cst); }
1670 template<
typename _ITp>
1672 atomic_fetch_min(
volatile __atomic_base<_ITp>* __a,
1673 __atomic_val_t<_ITp> __i)
noexcept
1674 {
return atomic_fetch_min_explicit(__a, __i, memory_order_seq_cst); }
1676 template<
typename _ITp>
1678 atomic_fetch_max(__atomic_base<_ITp>* __a,
1679 __atomic_val_t<_ITp> __i)
noexcept
1680 {
return atomic_fetch_max_explicit(__a, __i, memory_order_seq_cst); }
1682 template<
typename _ITp>
1684 atomic_fetch_max(
volatile __atomic_base<_ITp>* __a,
1685 __atomic_val_t<_ITp> __i)
noexcept
1686 {
return atomic_fetch_max_explicit(__a, __i, memory_order_seq_cst); }
1689#ifdef __cpp_lib_atomic_float
1691 struct atomic<float> : __atomic_float<float>
1693 atomic() noexcept = default;
1696 atomic(
float __fp) noexcept : __atomic_float<
float>(__fp)
1699 atomic& operator=(
const atomic&)
volatile =
delete;
1700 atomic& operator=(
const atomic&) =
delete;
1702 using __atomic_float<
float>::operator=;
1706 struct atomic<double> : __atomic_float<double>
1708 atomic() noexcept = default;
1711 atomic(
double __fp) noexcept : __atomic_float<
double>(__fp)
1714 atomic& operator=(
const atomic&)
volatile =
delete;
1715 atomic& operator=(
const atomic&) =
delete;
1717 using __atomic_float<
double>::operator=;
1721 struct atomic<long double> : __atomic_float<long double>
1723 atomic() noexcept = default;
1726 atomic(
long double __fp) noexcept : __atomic_float<
long double>(__fp)
1729 atomic& operator=(
const atomic&)
volatile =
delete;
1730 atomic& operator=(
const atomic&) =
delete;
1732 using __atomic_float<
long double>::operator=;
1735#ifdef __STDCPP_FLOAT16_T__
1737 struct atomic<_Float16> : __atomic_float<_Float16>
1739 atomic() noexcept = default;
1742 atomic(_Float16 __fp) noexcept : __atomic_float<_Float16>(__fp)
1745 atomic& operator=(
const atomic&)
volatile =
delete;
1746 atomic& operator=(
const atomic&) =
delete;
1748 using __atomic_float<_Float16>::operator=;
1752#ifdef __STDCPP_FLOAT32_T__
1754 struct atomic<_Float32> : __atomic_float<_Float32>
1756 atomic() noexcept = default;
1759 atomic(_Float32 __fp) noexcept : __atomic_float<_Float32>(__fp)
1762 atomic& operator=(
const atomic&)
volatile =
delete;
1763 atomic& operator=(
const atomic&) =
delete;
1765 using __atomic_float<_Float32>::operator=;
1769#ifdef __STDCPP_FLOAT64_T__
1771 struct atomic<_Float64> : __atomic_float<_Float64>
1773 atomic() noexcept = default;
1776 atomic(_Float64 __fp) noexcept : __atomic_float<_Float64>(__fp)
1779 atomic& operator=(
const atomic&)
volatile =
delete;
1780 atomic& operator=(
const atomic&) =
delete;
1782 using __atomic_float<_Float64>::operator=;
1786#ifdef __STDCPP_FLOAT128_T__
1788 struct atomic<_Float128> : __atomic_float<_Float128>
1790 atomic() noexcept = default;
1793 atomic(_Float128 __fp) noexcept : __atomic_float<_Float128>(__fp)
1796 atomic& operator=(
const atomic&)
volatile =
delete;
1797 atomic& operator=(
const atomic&) =
delete;
1799 using __atomic_float<_Float128>::operator=;
1803#ifdef __STDCPP_BFLOAT16_T__
1805 struct atomic<__gnu_cxx::__bfloat16_t> : __atomic_float<__gnu_cxx::__bfloat16_t>
1807 atomic() noexcept = default;
1810 atomic(__gnu_cxx::__bfloat16_t __fp) noexcept : __atomic_float<__gnu_cxx::__bfloat16_t>(__fp)
1813 atomic& operator=(
const atomic&)
volatile =
delete;
1814 atomic& operator=(
const atomic&) =
delete;
1816 using __atomic_float<__gnu_cxx::__bfloat16_t>::operator=;
1821#ifdef __cpp_lib_atomic_ref
1823 template<
typename _Tp>
1824 struct atomic_ref : __atomic_ref<_Tp>
1827 atomic_ref(_Tp& __t) noexcept
1830 __glibcxx_assert(((__UINTPTR_TYPE__)this->_M_ptr % this->required_alignment) == 0);
1836 atomic_ref(_Tp&&) =
delete;
1838 template<
typename _Up>
1839 requires is_convertible_v<_Up(*)[1], _Tp(*)[1]>
1840 atomic_ref(atomic_ref<_Up> __other) noexcept
1841 : __atomic_ref<_Tp>(__other._M_ptr)
1844 atomic_ref& operator=(
const atomic_ref&) =
delete;
1846 atomic_ref(
const atomic_ref&) =
default;
1848 using __atomic_ref<_Tp>::operator=;
1851 friend struct atomic_ref;
1855#ifdef __cpp_lib_atomic_lock_free_type_aliases
1856# ifdef _GLIBCXX_HAVE_PLATFORM_WAIT
1857 using atomic_signed_lock_free
1859 using atomic_unsigned_lock_free
1861# elif ATOMIC_INT_LOCK_FREE == 2
1864# elif ATOMIC_LONG_LOCK_FREE == 2
1867# elif ATOMIC_CHAR_LOCK_FREE == 2
1871# error "libstdc++ bug: no lock-free atomics but they were emitted in <version>"
1877_GLIBCXX_END_NAMESPACE_VERSION
constexpr _Tp * addressof(_Tp &__r) noexcept
Returns the actual address of the object or function referenced by r, even in the presence of an over...
constexpr _Tp * __addressof(_Tp &__r) noexcept
Same as C++11 std::addressof.
atomic< unsigned long > atomic_ulong
atomic_ulong
atomic< intmax_t > atomic_intmax_t
atomic_intmax_t
atomic< uintptr_t > atomic_uintptr_t
atomic_uintptr_t
atomic< signed char > atomic_schar
atomic_schar
atomic< int_least8_t > atomic_int_least8_t
atomic_int_least8_t
atomic< unsigned long long > atomic_ullong
atomic_ullong
atomic< uint_fast8_t > atomic_uint_fast8_t
atomic_uint_fast8_t
atomic< intptr_t > atomic_intptr_t
atomic_intptr_t
atomic< int16_t > atomic_int16_t
atomic_int16_t
atomic< size_t > atomic_size_t
atomic_size_t
atomic< long > atomic_long
atomic_long
atomic< uint_least8_t > atomic_uint_least8_t
atomic_uint_least8_t
atomic< short > atomic_short
atomic_short
atomic< uint_least16_t > atomic_uint_least16_t
atomic_uint_least16_t
atomic< uint16_t > atomic_uint16_t
atomic_uint16_t
atomic< uint64_t > atomic_uint64_t
atomic_uint64_t
atomic< int_least32_t > atomic_int_least32_t
atomic_int_least32_t
atomic< uint8_t > atomic_uint8_t
atomic_uint8_t
#define ATOMIC_BOOL_LOCK_FREE
atomic< wchar_t > atomic_wchar_t
atomic_wchar_t
atomic< unsigned int > atomic_uint
atomic_uint
atomic< uint_least32_t > atomic_uint_least32_t
atomic_uint_least32_t
atomic< uint_fast64_t > atomic_uint_fast64_t
atomic_uint_fast64_t
atomic< int_fast32_t > atomic_int_fast32_t
atomic_int_fast32_t
atomic< char > atomic_char
atomic_char
atomic< int > atomic_int
atomic_int
atomic< uint_least64_t > atomic_uint_least64_t
atomic_uint_least64_t
atomic< int64_t > atomic_int64_t
atomic_int64_t
atomic< uintmax_t > atomic_uintmax_t
atomic_uintmax_t
atomic< int_fast16_t > atomic_int_fast16_t
atomic_int_fast16_t
atomic< int32_t > atomic_int32_t
atomic_int32_t
atomic< uint_fast16_t > atomic_uint_fast16_t
atomic_uint_fast16_t
atomic< int8_t > atomic_int8_t
atomic_int8_t
atomic< long long > atomic_llong
atomic_llong
atomic< char16_t > atomic_char16_t
atomic_char16_t
atomic< int_fast64_t > atomic_int_fast64_t
atomic_int_fast64_t
atomic< ptrdiff_t > atomic_ptrdiff_t
atomic_ptrdiff_t
atomic< char32_t > atomic_char32_t
atomic_char32_t
atomic< int_least16_t > atomic_int_least16_t
atomic_int_least16_t
atomic< unsigned char > atomic_uchar
atomic_uchar
atomic< int_fast8_t > atomic_int_fast8_t
atomic_int_fast8_t
memory_order
Enumeration for memory_order.
atomic< unsigned short > atomic_ushort
atomic_ushort
atomic< int_least64_t > atomic_int_least64_t
atomic_int_least64_t
atomic< bool > atomic_bool
atomic_bool
atomic< uint_fast32_t > atomic_uint_fast32_t
atomic_uint_fast32_t
atomic< uint32_t > atomic_uint32_t
atomic_uint32_t
ISO C++ entities toplevel namespace is std.
Generic atomic type, primary class template.