Core: In R4300iOp have a member variable for system, reg, mmu
This commit is contained in:
parent
ae0097550f
commit
4d78f56aa2
File diff suppressed because it is too large
Load Diff
|
@ -14,7 +14,7 @@ class R4300iOp :
|
|||
friend CX86RecompilerOps;
|
||||
|
||||
public:
|
||||
R4300iOp();
|
||||
R4300iOp(CN64System & System);
|
||||
~R4300iOp(void);
|
||||
|
||||
void ExecuteCPU();
|
||||
|
@ -27,6 +27,7 @@ public:
|
|||
}
|
||||
|
||||
private:
|
||||
R4300iOp();
|
||||
R4300iOp(const R4300iOp &);
|
||||
R4300iOp & operator=(const R4300iOp &);
|
||||
|
||||
|
@ -258,6 +259,9 @@ private:
|
|||
void ReservedInstruction();
|
||||
void UnknownOpcode();
|
||||
|
||||
CN64System & m_System;
|
||||
CRegisters & m_Reg;
|
||||
CMipsMemoryVM & m_MMU;
|
||||
R4300iOpcode m_Opcode;
|
||||
|
||||
Func Jump_Opcode[64];
|
||||
|
@ -273,16 +277,16 @@ private:
|
|||
Func Jump_CoP1_L[64];
|
||||
Func Jump_CoP2[32];
|
||||
|
||||
static bool TestCop1UsableException(void);
|
||||
static bool CheckFPUInput32(const float & Value);
|
||||
static bool CheckFPUInput32Conv(const float & Value);
|
||||
static bool CheckFPUInput64(const double & Value);
|
||||
static bool CheckFPUInput64Conv(const double & Value);
|
||||
static bool CheckFPUResult32(float & Result);
|
||||
static bool CheckFPUResult64(double & Result);
|
||||
static bool CheckFPUInvalidException(void);
|
||||
static bool InitFpuOperation(FPRoundingMode RoundingModel);
|
||||
static bool SetFPUException(void);
|
||||
bool TestCop1UsableException(void);
|
||||
bool CheckFPUInput32(const float & Value);
|
||||
bool CheckFPUInput32Conv(const float & Value);
|
||||
bool CheckFPUInput64(const double & Value);
|
||||
bool CheckFPUInput64Conv(const double & Value);
|
||||
bool CheckFPUResult32(float & Result);
|
||||
bool CheckFPUResult64(double & Result);
|
||||
bool CheckFPUInvalidException(void);
|
||||
bool InitFpuOperation(FPRoundingMode RoundingModel);
|
||||
bool SetFPUException(void);
|
||||
|
||||
static const uint32_t SWL_MASK[4], SWR_MASK[4], LWL_MASK[4], LWR_MASK[4];
|
||||
static const int32_t SWL_SHIFT[4], SWR_SHIFT[4], LWL_SHIFT[4], LWR_SHIFT[4];
|
||||
|
|
|
@ -33,6 +33,7 @@ CN64System::CN64System(CPlugins * Plugins, uint32_t randomizer_seed, bool SavesR
|
|||
//m_Cheats(m_MMU_VM),
|
||||
m_Reg(*this, *this),
|
||||
m_TLB(m_MMU_VM, m_Reg, m_Recomp),
|
||||
m_OpCodes(*this),
|
||||
m_Recomp(nullptr),
|
||||
m_InReset(false),
|
||||
m_NextTimer(0),
|
||||
|
|
|
@ -8583,7 +8583,7 @@ void CX86RecompilerOps::CompileCheckFPUInput32(asmjit::x86::Gp RegPointer)
|
|||
m_Assembler.MoveConstToVariable(&g_System->m_PipelineStage, "System->m_PipelineStage", m_PipelineStage == PIPELINE_STAGE_JUMP || m_PipelineStage == PIPELINE_STAGE_DELAY_SLOT ? PIPELINE_STAGE_JUMP : PIPELINE_STAGE_NORMAL);
|
||||
m_Assembler.MoveConstToVariable(&m_Reg.m_PROGRAM_COUNTER, "PROGRAM_COUNTER", m_CompilePC);
|
||||
m_Assembler.PushImm32("m_TempValue32", (uint32_t)&m_TempValue32);
|
||||
m_Assembler.CallFunc((uint32_t)R4300iOp::CheckFPUInput32, "R4300iOp::CheckFPUInput32");
|
||||
m_Assembler.CallThis((uint32_t)&g_System->m_OpCodes, AddressOf(&R4300iOp::CheckFPUInput32), "R4300iOp::CheckFPUInput32", 4);
|
||||
m_Assembler.add(asmjit::x86::esp, 4);
|
||||
m_Assembler.test(asmjit::x86::al, asmjit::x86::al);
|
||||
m_RegWorkingSet.AfterCallDirect();
|
||||
|
@ -8620,7 +8620,7 @@ void CX86RecompilerOps::CompileCheckFPUResult32(int32_t DestReg)
|
|||
m_Assembler.MoveConstToVariable(&g_System->m_PipelineStage, "System->m_PipelineStage", m_PipelineStage == PIPELINE_STAGE_JUMP || m_PipelineStage == PIPELINE_STAGE_DELAY_SLOT ? PIPELINE_STAGE_JUMP : PIPELINE_STAGE_NORMAL);
|
||||
m_Assembler.MoveConstToVariable(&m_Reg.m_PROGRAM_COUNTER, "PROGRAM_COUNTER", m_CompilePC);
|
||||
m_Assembler.PushImm32("Result", (uint32_t)&m_TempValue32);
|
||||
m_Assembler.CallFunc((uint32_t)R4300iOp::CheckFPUResult32, "R4300iOp::CheckFPUResult32");
|
||||
m_Assembler.CallThis((uint32_t)&g_System->m_OpCodes, AddressOf(&R4300iOp::CheckFPUResult32), "R4300iOp::CheckFPUResult32", 4);
|
||||
m_Assembler.add(asmjit::x86::esp, 4);
|
||||
m_Assembler.test(asmjit::x86::al, asmjit::x86::al);
|
||||
m_RegWorkingSet.AfterCallDirect();
|
||||
|
|
Loading…
Reference in New Issue