Replace dependency on SmartPtr with primitives in Core

This commit is contained in:
Christian Mazakas
2023-06-02 14:14:18 -07:00
parent 44c50cd2ea
commit 8877d21237
3 changed files with 5 additions and 8 deletions

View File

@ -22,7 +22,6 @@ target_link_libraries(boost_unordered
Boost::mp11 Boost::mp11
Boost::predef Boost::predef
Boost::preprocessor Boost::preprocessor
Boost::smart_ptr
Boost::static_assert Boost::static_assert
Boost::throw_exception Boost::throw_exception
Boost::tuple Boost::tuple

View File

@ -5,8 +5,7 @@
// Distributed under the Boost Software License, Version 1.0. // Distributed under the Boost Software License, Version 1.0.
// https://www.boost.org/LICENSE_1_0.txt // https://www.boost.org/LICENSE_1_0.txt
#include <boost/smart_ptr/detail/sp_thread_pause.hpp> #include <boost/core/yield_primitives.hpp>
#include <boost/smart_ptr/detail/sp_thread_sleep.hpp>
#include <atomic> #include <atomic>
#include <cstdint> #include <cstdint>
@ -64,10 +63,10 @@ public:
if( state_.compare_exchange_weak( st, newst, std::memory_order_acquire, std::memory_order_relaxed ) ) return; if( state_.compare_exchange_weak( st, newst, std::memory_order_acquire, std::memory_order_relaxed ) ) return;
} }
boost::detail::sp_thread_pause(); boost::core::sp_thread_pause();
} }
boost::detail::sp_thread_sleep(); boost::core::sp_thread_sleep();
} }
} }
@ -132,7 +131,7 @@ public:
state_.compare_exchange_weak( st, newst, std::memory_order_relaxed, std::memory_order_relaxed ); state_.compare_exchange_weak( st, newst, std::memory_order_relaxed, std::memory_order_relaxed );
} }
boost::detail::sp_thread_pause(); boost::core::sp_thread_pause();
} }
// clear writer pending bit before going to sleep // clear writer pending bit before going to sleep
@ -169,7 +168,7 @@ public:
} }
} }
boost::detail::sp_thread_sleep(); boost::core::sp_thread_sleep();
} }
} }

View File

@ -22,7 +22,6 @@ move
mp11 mp11
predef predef
preprocessor preprocessor
smart_ptr
static_assert static_assert
throw_exception throw_exception
tuple tuple