RSP: add RomOpen and JumpTableSize Setting

This commit is contained in:
zilmar 2013-02-11 19:27:49 +11:00
parent 229be28668
commit 14352768ae
1 changed files with 21 additions and 1 deletions

View File

@ -76,6 +76,9 @@ enum {
//Compiler settings
Set_CheckDest, Set_Accum, Set_Mmx, Set_Mmx2, Set_Sse, Set_Sections,
Set_ReOrdering, Set_GPRConstants, Set_Flags, Set_AlignVector,
//Game Settings
Set_JumpTableSize
};
short Set_AudioHle = 0, Set_GraphicsHle = 0;
@ -475,6 +478,22 @@ void ProcessMenuItem(int ID) {
#endif
/******************************************************************
Function: RomOpen
Purpose: This function is called when a rom is opened.
input: none
output: none
*******************************************************************/
__declspec(dllexport) void RomOpen (void)
{
ClearAllx86Code();
if (DebuggingEnabled)
{
EnableDebugging(true);
}
JumpTableSize = GetSetting(Set_JumpTableSize);
}
/******************************************************************
Function: RomClosed
Purpose: This function is called when a rom is closed.
@ -486,7 +505,6 @@ __declspec(dllexport) void RomClosed (void) {
StopTimer();
GenerateTimerResults();
}
InitilizeRSPRegisters();
ClearAllx86Code();
StopRDPLog();
StopCPULog();
@ -712,6 +730,8 @@ __declspec(dllexport) void PluginLoaded (void)
RegisterSetting(Set_Flags, Data_DWORD_General,"Check Flag Usage", NULL,Compiler.bFlags,NULL);
RegisterSetting(Set_AlignVector, Data_DWORD_General,"Assume Vector loads align", NULL,Compiler.bAlignVector,NULL);
RegisterSetting(Set_JumpTableSize, Data_DWORD_Game,"JumpTableSize",NULL,0x800,NULL);
AudioHle = Set_AudioHle != 0 ? GetSystemSetting(Set_AudioHle) : false;
GraphicsHle = Set_GraphicsHle != 0 ? GetSystemSetting(Set_GraphicsHle) : true;