mirror of
https://github.com/RPCS3/rpcs3.git
synced 2025-07-06 23:11:25 +12:00
Make sys_spu_thread_group_join return once per termination
This commit is contained in:
parent
19ff95da70
commit
e3ee481f01
3 changed files with 16 additions and 35 deletions
|
@ -521,6 +521,11 @@ void spu_thread::cpu_stop()
|
|||
group->stop_count++;
|
||||
group->run_state = SPU_THREAD_GROUP_STATUS_INITIALIZED;
|
||||
|
||||
if (!group->join_state)
|
||||
{
|
||||
group->join_state = SYS_SPU_THREAD_GROUP_JOIN_ALL_THREADS_EXIT;
|
||||
}
|
||||
|
||||
if (const auto ppu = std::exchange(group->waiter, nullptr))
|
||||
{
|
||||
// Send exit status directly to the joining thread
|
||||
|
@ -2436,7 +2441,7 @@ bool spu_thread::stop_and_signal(u32 code)
|
|||
}
|
||||
|
||||
group->exit_status = value;
|
||||
group->join_state |= SPU_TGJSF_GROUP_EXIT;
|
||||
group->join_state = SYS_SPU_THREAD_GROUP_JOIN_GROUP_EXIT;
|
||||
|
||||
state += cpu_flag::stop;
|
||||
return true;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue