mirror of
https://github.com/RPCS3/rpcs3.git
synced 2025-04-28 21:38:01 +03:00
Homebrew atomic_ptr rewritten (util/shared_ptr.hpp)
It's analogous to C++20 atomic std::shared_ptr The following things brought into global namespace: single_ptr shared_ptr atomic_ptr make_single
This commit is contained in:
parent
bd90e3e37f
commit
b5d498ffda
15 changed files with 732 additions and 597 deletions
|
@ -2242,7 +2242,7 @@ std::string thread_ctrl::get_name_cached()
|
|||
return {};
|
||||
}
|
||||
|
||||
static thread_local stx::shared_cptr<std::string> name_cache;
|
||||
static thread_local shared_ptr<std::string> name_cache;
|
||||
|
||||
if (!_this->m_tname.is_equal(name_cache)) [[unlikely]]
|
||||
{
|
||||
|
@ -2254,7 +2254,7 @@ std::string thread_ctrl::get_name_cached()
|
|||
|
||||
thread_base::thread_base(native_entry entry, std::string_view name)
|
||||
: entry_point(entry)
|
||||
, m_tname(stx::shared_cptr<std::string>::make(name))
|
||||
, m_tname(make_single<std::string>(name))
|
||||
{
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue