mirror of
https://github.com/RPCS3/rpcs3.git
synced 2025-07-03 21:41:26 +12:00
atomic.hpp: Fix atomic_storage_futex::raw_notify
This commit is contained in:
parent
3206378ae6
commit
fe9c61fe73
2 changed files with 4 additions and 3 deletions
|
@ -314,13 +314,14 @@ class named_thread final : public Context, result_storage_t<Context>, thread_bas
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
_this->m_state_notifier.release(data);
|
|
||||||
|
|
||||||
if (!data)
|
if (!data)
|
||||||
{
|
{
|
||||||
|
_this->m_state_notifier.release(data);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
_this->m_state_notifier.store(data);
|
||||||
|
|
||||||
if (_this->m_state >= thread_state::aborting)
|
if (_this->m_state >= thread_state::aborting)
|
||||||
{
|
{
|
||||||
_this->m_state_notifier.release(nullptr);
|
_this->m_state_notifier.release(nullptr);
|
||||||
|
|
|
@ -536,7 +536,7 @@ void atomic_storage_futex::wait(const void* data, std::size_t size, u64 old_valu
|
||||||
|
|
||||||
bool fallback = false;
|
bool fallback = false;
|
||||||
|
|
||||||
if (sema_id && ptr_cmp(data, size, old_value, mask) && s_tls_wait_cb(data))
|
if (sema_id && s_tls_wait_cb(data) && ptr_cmp(data, size, old_value, mask))
|
||||||
{
|
{
|
||||||
#ifdef USE_FUTEX
|
#ifdef USE_FUTEX
|
||||||
struct timespec ts;
|
struct timespec ts;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue