mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-22 22:00:39 -06:00
Experimental commit and one fix for my last commit.
I think that isFifoBusy bring better sync with VI (video interface) because the CPU emulated threads are waiting for DrawDone in BP Register. So, I do some modifications. 1) Rename "IsFifoBusy" by "isPossibleWaitingSetDrawDone" 2) Only activate isPossibleWaitingSetDrawDone when bFF_GPLinkEnable is true in fifo loop "Inmediate mode" that is because in theory this drawsync function is using in this mode. 3) Deactivate isPossibleWaitingSetDrawDone also in SetFinish in PixelEngine, beside when 32 block is finish. Please regression in yours games thats can bring some FPS more above all with VPS frame limiter ON (Auto, 60, 50, etc). - Fix waiting in AbortFrame(), please test mp1/mp2 is fixed again. Good look! git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7123 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
@ -33,6 +33,7 @@ namespace
|
||||
{
|
||||
static volatile bool fifoStateRun = false;
|
||||
static volatile bool EmuRunning = false;
|
||||
static volatile bool isFifoProcesingData = false;
|
||||
static u8 *videoBuffer;
|
||||
// STATE_TO_SAVE
|
||||
static int size = 0;
|
||||
@ -95,6 +96,11 @@ void Fifo_RunLoop(bool run)
|
||||
EmuRunning = run;
|
||||
}
|
||||
|
||||
bool IsFifoProcesingData()
|
||||
{
|
||||
return isFifoProcesingData;
|
||||
}
|
||||
|
||||
// Description: Fifo_EnterLoop() sends data through this function.
|
||||
void Fifo_SendFifoData(u8* _uData, u32 len)
|
||||
{
|
||||
@ -142,9 +148,8 @@ void Fifo_EnterLoop()
|
||||
while (!CommandProcessor::interruptWaiting && _fifo.bFF_GPReadEnable &&
|
||||
_fifo.CPReadWriteDistance && (!AtBreakpoint() || CommandProcessor::OnOverflow))
|
||||
{
|
||||
// while the FIFO is processing data we activate this for sync with emulator thread.
|
||||
|
||||
CommandProcessor::isFifoBusy = true;
|
||||
isFifoProcesingData = true;
|
||||
CommandProcessor::isPossibleWaitingSetDrawDone = _fifo.bFF_GPLinkEnable;
|
||||
|
||||
if (!fifoStateRun) break;
|
||||
|
||||
@ -180,9 +185,10 @@ void Fifo_EnterLoop()
|
||||
// If we don't, s_swapRequested or s_efbAccessRequested won't be set to false
|
||||
// leading the CPU thread to wait in Video_BeginField or Video_AccessEFB thus slowing things down.
|
||||
VideoFifo_CheckAsyncRequest();
|
||||
CommandProcessor::isFifoBusy = false;
|
||||
CommandProcessor::isPossibleWaitingSetDrawDone = false;
|
||||
}
|
||||
|
||||
|
||||
isFifoProcesingData = false;
|
||||
|
||||
CommandProcessor::SetFifoIdleFromVideoPlugin();
|
||||
|
||||
|
Reference in New Issue
Block a user