mirror of
https://github.com/RPCS3/rpcs3.git
synced 2025-07-09 16:31:28 +12:00
Implement atomic_t<>::release
More relaxed store with release memory order
This commit is contained in:
parent
50922faac9
commit
2b66abaf10
4 changed files with 60 additions and 26 deletions
|
@ -85,7 +85,7 @@ namespace vm
|
|||
if (!lock && lock.compare_and_swap_test(0, lock_info))
|
||||
{
|
||||
return &lock;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -256,7 +256,7 @@ namespace vm
|
|||
{
|
||||
const u64 value = lock;
|
||||
|
||||
// Test beginning address
|
||||
// Test beginning address
|
||||
if (static_cast<u32>(value) > addr)
|
||||
{
|
||||
break;
|
||||
|
@ -295,7 +295,7 @@ namespace vm
|
|||
|
||||
writer_lock::~writer_lock()
|
||||
{
|
||||
g_addr_lock.raw() = 0;
|
||||
g_addr_lock.release(0);
|
||||
g_mutex.unlock();
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue