mirror of
https://github.com/RPCSX/rpcsx.git
synced 2026-04-05 14:37:08 +00: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
|
|
@ -915,7 +915,7 @@ ppu_thread::ppu_thread(const ppu_thread_params& param, std::string_view name, u3
|
|||
, joiner(detached != 0 ? ppu_join_status::detached : ppu_join_status::joinable)
|
||||
, entry_func(param.entry)
|
||||
, start_time(get_guest_system_time())
|
||||
, ppu_tname(stx::shared_cptr<std::string>::make(name))
|
||||
, ppu_tname(make_single<std::string>(name))
|
||||
{
|
||||
gpr[1] = stack_addr + stack_size - ppu_stack_start_offset;
|
||||
|
||||
|
|
@ -1020,7 +1020,7 @@ void ppu_thread::fast_call(u32 addr, u32 rtoc)
|
|||
{
|
||||
const auto _this = static_cast<ppu_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 (!_this->ppu_tname.is_equal(name_cache)) [[unlikely]]
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue