File indexing completed on 2025-01-18 09:51:42
0001 #ifndef BOOST_SMART_PTR_DETAIL_ATOMIC_COUNT_HPP_INCLUDED
0002 #define BOOST_SMART_PTR_DETAIL_ATOMIC_COUNT_HPP_INCLUDED
0003
0004
0005
0006 #if defined(_MSC_VER) && (_MSC_VER >= 1020)
0007 # pragma once
0008 #endif
0009
0010
0011
0012
0013
0014
0015
0016
0017
0018
0019
0020
0021
0022
0023
0024
0025
0026
0027
0028
0029
0030
0031
0032
0033
0034
0035
0036
0037
0038
0039
0040
0041
0042
0043
0044
0045
0046 #include <boost/smart_ptr/detail/sp_has_gcc_intrinsics.hpp>
0047 #include <boost/smart_ptr/detail/sp_has_sync_intrinsics.hpp>
0048 #include <boost/config.hpp>
0049
0050 #if defined( BOOST_AC_DISABLE_THREADS )
0051 # include <boost/smart_ptr/detail/atomic_count_nt.hpp>
0052
0053 #elif defined( BOOST_AC_USE_STD_ATOMIC )
0054 # include <boost/smart_ptr/detail/atomic_count_std_atomic.hpp>
0055
0056 #elif defined( BOOST_AC_USE_SPINLOCK )
0057 # include <boost/smart_ptr/detail/atomic_count_spin.hpp>
0058
0059 #elif defined( BOOST_AC_USE_PTHREADS )
0060 # include <boost/smart_ptr/detail/atomic_count_pt.hpp>
0061
0062 #elif defined( BOOST_SP_DISABLE_THREADS )
0063 # include <boost/smart_ptr/detail/atomic_count_nt.hpp>
0064
0065 #elif defined( BOOST_SP_USE_STD_ATOMIC )
0066 # include <boost/smart_ptr/detail/atomic_count_std_atomic.hpp>
0067
0068 #elif defined( BOOST_SP_USE_SPINLOCK )
0069 # include <boost/smart_ptr/detail/atomic_count_spin.hpp>
0070
0071 #elif defined( BOOST_SP_USE_PTHREADS )
0072 # include <boost/smart_ptr/detail/atomic_count_pt.hpp>
0073
0074 #elif defined( BOOST_DISABLE_THREADS ) && !defined( BOOST_SP_ENABLE_THREADS ) && !defined( BOOST_DISABLE_WIN32 )
0075 # include <boost/smart_ptr/detail/atomic_count_nt.hpp>
0076
0077 #elif defined( BOOST_SP_HAS_GCC_INTRINSICS )
0078 # include <boost/smart_ptr/detail/atomic_count_gcc_atomic.hpp>
0079
0080 #elif !defined( BOOST_NO_CXX11_HDR_ATOMIC )
0081 # include <boost/smart_ptr/detail/atomic_count_std_atomic.hpp>
0082
0083 #elif defined( BOOST_SP_HAS_SYNC_INTRINSICS )
0084 # include <boost/smart_ptr/detail/atomic_count_sync.hpp>
0085
0086 #elif defined( __GNUC__ ) && ( defined( __i386__ ) || defined( __x86_64__ ) ) && !defined( __PATHSCALE__ )
0087 # include <boost/smart_ptr/detail/atomic_count_gcc_x86.hpp>
0088
0089 #elif defined(WIN32) || defined(_WIN32) || defined(__WIN32__) || defined(__CYGWIN__)
0090 # include <boost/smart_ptr/detail/atomic_count_win32.hpp>
0091
0092 #elif defined(__GLIBCPP__) || defined(__GLIBCXX__)
0093 # include <boost/smart_ptr/detail/atomic_count_gcc.hpp>
0094
0095 #elif !defined( BOOST_HAS_THREADS )
0096 # include <boost/smart_ptr/detail/atomic_count_nt.hpp>
0097
0098 #else
0099 # include <boost/smart_ptr/detail/atomic_count_spin.hpp>
0100
0101 #endif
0102
0103 #endif