mirror of
https://github.com/RPCS3/rpcs3.git
synced 2025-07-06 06:51:26 +12: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
|
@ -1572,7 +1572,7 @@ void spu_thread::cpu_task()
|
|||
{
|
||||
const auto cpu = static_cast<spu_thread*>(get_current_cpu_thread());
|
||||
|
||||
static thread_local stx::shared_cptr<std::string> name_cache;
|
||||
static thread_local shared_ptr<std::string> name_cache;
|
||||
|
||||
if (!cpu->spu_tname.is_equal(name_cache)) [[unlikely]]
|
||||
{
|
||||
|
@ -1692,7 +1692,7 @@ spu_thread::spu_thread(lv2_spu_group* group, u32 index, std::string_view name, u
|
|||
, group(group)
|
||||
, option(option)
|
||||
, lv2_id(lv2_id)
|
||||
, spu_tname(stx::shared_cptr<std::string>::make(name))
|
||||
, spu_tname(make_single<std::string>(name))
|
||||
{
|
||||
if (g_cfg.core.spu_decoder == spu_decoder_type::asmjit)
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue