Avoid a possible thread sync issue.

Could be that it's about to wake listsync, does, and then we wait.
This commit is contained in:
Unknown W. Brackets 2013-08-10 16:16:54 -07:00
parent 0ef02cddfa
commit 55c07bdc73

View File

@ -130,7 +130,6 @@ int GPUCommon::ListSync(int listid, int mode) {
} }
if (dl.waitTicks > CoreTiming::GetTicks()) { if (dl.waitTicks > CoreTiming::GetTicks()) {
guard.unlock();
__KernelWaitCurThread(WAITTYPE_GELISTSYNC, listid, 0, 0, false, "GeListSync"); __KernelWaitCurThread(WAITTYPE_GELISTSYNC, listid, 0, 0, false, "GeListSync");
} }
return PSP_GE_LIST_COMPLETED; return PSP_GE_LIST_COMPLETED;
@ -244,7 +243,6 @@ u32 GPUCommon::DequeueList(int listid) {
dlQueue.remove(listid); dlQueue.remove(listid);
dls[listid].waitTicks = 0; dls[listid].waitTicks = 0;
guard.unlock();
__KernelTriggerWait(WAITTYPE_GELISTSYNC, listid, 0, "GeListSync"); __KernelTriggerWait(WAITTYPE_GELISTSYNC, listid, 0, "GeListSync");
CheckDrawSync(); CheckDrawSync();
@ -599,7 +597,6 @@ void GPUCommon::ProcessDLQueueInternal() {
easy_guard guard(listLock); easy_guard guard(listLock);
currentList = NULL; currentList = NULL;
guard.unlock();
drawCompleteTicks = startingTicks + cyclesExecuted; drawCompleteTicks = startingTicks + cyclesExecuted;
busyTicks = std::max(busyTicks, drawCompleteTicks); busyTicks = std::max(busyTicks, drawCompleteTicks);