mirror of https://github.com/PCSX2/pcsx2.git
Fixed savestates for vtlb builds. They're much more reliable now :)
git-svn-id: http://pcsx2-playground.googlecode.com/svn/trunk@628 a6443dda-0b58-4228-96e9-037be469359c
This commit is contained in:
parent
9be927fd7a
commit
7a456fe608
|
@ -36,11 +36,15 @@
|
|||
using namespace R5900;
|
||||
|
||||
extern int g_psxWriteOk;
|
||||
extern void recResetEE();
|
||||
extern void recResetIOP();
|
||||
|
||||
// STATES
|
||||
|
||||
static void PreLoadPrep()
|
||||
{
|
||||
recResetEE();
|
||||
recResetIOP();
|
||||
#ifdef PCSX2_VIRTUAL_MEM
|
||||
DWORD OldProtect;
|
||||
// make sure can write
|
||||
|
|
|
@ -608,9 +608,9 @@ static void recAlloc()
|
|||
ProfilerRegisterSource( "IOPRec", recMem, RECMEM_SIZE );
|
||||
}
|
||||
|
||||
static void recReset()
|
||||
void recResetIOP()
|
||||
{
|
||||
// calling recReset without first calling recInit is bad mojo.
|
||||
// calling recResetIOP without first calling recInit is bad mojo.
|
||||
jASSUME( psxRecLUT != NULL );
|
||||
jASSUME( recMem != NULL );
|
||||
jASSUME( m_recBlockAlloc != NULL );
|
||||
|
@ -1312,7 +1312,7 @@ void psxRecRecompile(u32 startpc)
|
|||
// if recPtr reached the mem limit reset whole mem
|
||||
if (((uptr)recPtr - (uptr)recMem) >= (RECMEM_SIZE - 0x10000)) {
|
||||
DevCon::WriteLn("IOP Recompiler data reset");
|
||||
recReset();
|
||||
recResetIOP();
|
||||
}
|
||||
|
||||
s_pCurBlock = PSX_GETBLOCK(startpc);
|
||||
|
@ -1339,7 +1339,7 @@ void psxRecRecompile(u32 startpc)
|
|||
|
||||
if( s_pCurBlockEx == NULL ) {
|
||||
DevCon::WriteLn("IOP Recompiler data reset");
|
||||
recReset();
|
||||
recResetIOP();
|
||||
s_nNextBlock = 0;
|
||||
s_pCurBlockEx = recBlocks;
|
||||
}
|
||||
|
@ -1591,7 +1591,7 @@ StartRecomp:
|
|||
|
||||
R3000Acpu psxRec = {
|
||||
recAlloc,
|
||||
recReset,
|
||||
recResetIOP,
|
||||
recExecute,
|
||||
recExecuteBlock,
|
||||
recClear,
|
||||
|
|
|
@ -555,7 +555,7 @@ static void recAlloc()
|
|||
}
|
||||
|
||||
////////////////////////////////////////////////////
|
||||
static void recReset( void )
|
||||
void recResetEE( void )
|
||||
{
|
||||
DbgCon::Status( "iR5900-32 > Resetting recompiler memory and structures." );
|
||||
|
||||
|
@ -1582,11 +1582,11 @@ void recRecompile( const u32 startpc )
|
|||
// if recPtr reached the mem limit reset whole mem
|
||||
if ( ( (uptr)recPtr - (uptr)recMem ) >= REC_CACHEMEM-0x40000 || dumplog == 0xffffffff) {
|
||||
DevCon::WriteLn( "EE Recompiler data reset" );
|
||||
recReset();
|
||||
recResetEE();
|
||||
}
|
||||
if ( ( (uptr)recStackPtr - (uptr)recStack ) >= RECSTACK_SIZE-0x100 ) {
|
||||
DevCon::WriteLn("EE recompiler stack reset");
|
||||
recReset();
|
||||
recResetEE();
|
||||
}
|
||||
|
||||
s_pCurBlock = PC_GETBLOCK(startpc);
|
||||
|
@ -1613,7 +1613,7 @@ void recRecompile( const u32 startpc )
|
|||
|
||||
if( s_pCurBlockEx == NULL ) {
|
||||
//SysPrintf("ee reset (blocks)\n");
|
||||
recReset();
|
||||
recResetEE();
|
||||
s_nNextBlock = 0;
|
||||
s_pCurBlockEx = recBlocks;
|
||||
}
|
||||
|
@ -2091,7 +2091,7 @@ StartRecomp:
|
|||
|
||||
R5900cpu recCpu = {
|
||||
recAlloc,
|
||||
recReset,
|
||||
recResetEE,
|
||||
recStep,
|
||||
recExecute,
|
||||
recExecuteBlock,
|
||||
|
|
Loading…
Reference in New Issue