From 1bd9f54c9b1b71d4d160c83d9498cc4cba3a79fa Mon Sep 17 00:00:00 2001 From: "Jake.Stine" Date: Fri, 31 Oct 2008 18:47:37 +0000 Subject: [PATCH] IOP Sync problems should be fixed now (yeah I said that 2 revisions ago too, I know). But this time I knew what to look for! spu2ghz stretch stats don't seem to crap out now. ;) git-svn-id: http://pcsx2-playground.googlecode.com/svn/trunk@258 a6443dda-0b58-4228-96e9-037be469359c --- pcsx2/R3000A.c | 11 ++++------- pcsx2/x86/iR3000A.cpp | 2 +- 2 files changed, 5 insertions(+), 8 deletions(-) diff --git a/pcsx2/R3000A.c b/pcsx2/R3000A.c index 8298aebd32..08b849385c 100644 --- a/pcsx2/R3000A.c +++ b/pcsx2/R3000A.c @@ -161,16 +161,13 @@ static void _psxTestInterrupts() { PSX_TESTINT(21, usbInterrupt); } - -// Can't safely lower the IOP wait cycle counter (yet). -// 128 might be a safe value but until I know what's cuasing it to -// suck at higher values I'll err on the side of caution. - -#define IOP_WAIT_CYCLE 64 // was (and is again!) 64 +#define IOP_WAIT_CYCLE 256 // was (and is again!) 64 void psxBranchTest() { - g_psxNextBranchCycle = psxRegs.cycle + IOP_WAIT_CYCLE; + // g_psxNextBranchCycle is initialized for us by iPsxBranchTest. + g_psxNextBranchCycle = psxRegs.cycle; + if( EEsCycle >= 0 ) g_psxNextBranchCycle += IOP_WAIT_CYCLE; if ((int)(psxRegs.cycle - psxNextsCounter) >= psxNextCounter) psxRcntUpdate(); diff --git a/pcsx2/x86/iR3000A.cpp b/pcsx2/x86/iR3000A.cpp index e98756d0bb..62f94c23a0 100644 --- a/pcsx2/x86/iR3000A.cpp +++ b/pcsx2/x86/iR3000A.cpp @@ -994,7 +994,7 @@ static void iPsxBranchTest(u32 newpc, u32 cpuBranch) // check if we've caught up with the EE SUB32ItoM((uptr)&EEsCycle, s_psxBlockCycles*PSXCYCLE_MULT*8); // 8 EE clocks for every IOP clock. - j8Ptr[2] = JG8(0); + j8Ptr[2] = JGE8(0); // Break the Block-execute Loop here. // (but not without running another branch test! And do it regardless