[Project64] remove CMipsMemory_CallBack
This commit is contained in:
parent
ff8623ad2c
commit
50c4030c62
|
@ -26,13 +26,12 @@ uint32_t CMipsMemoryVM::m_MemLookupAddress = 0;
|
|||
MIPS_DWORD CMipsMemoryVM::m_MemLookupValue;
|
||||
bool CMipsMemoryVM::m_MemLookupValid = true;
|
||||
|
||||
CMipsMemoryVM::CMipsMemoryVM(CMipsMemory_CallBack * CallBack, bool SavesReadOnly) :
|
||||
CMipsMemoryVM::CMipsMemoryVM(bool SavesReadOnly) :
|
||||
|
||||
CPifRam(SavesReadOnly),
|
||||
CFlashram(SavesReadOnly),
|
||||
CSram(SavesReadOnly),
|
||||
CDMA(*this, *this),
|
||||
m_CBClass(CallBack),
|
||||
m_RomMapped(false),
|
||||
m_Rom(NULL),
|
||||
m_RomSize(0),
|
||||
|
|
|
@ -18,12 +18,6 @@
|
|||
#include <Project64-core/N64System/Mips/Sram.h>
|
||||
#include <Project64-core/N64System/Mips/Dma.h>
|
||||
|
||||
__interface CMipsMemory_CallBack
|
||||
{
|
||||
//Protected memory has been written to, returns true if that memory has been unprotected
|
||||
virtual bool WriteToProtectedMemory(uint32_t Address, int32_t length) = 0;
|
||||
};
|
||||
|
||||
/*
|
||||
* 64-bit Windows exception recovery facilities will expect to interact with
|
||||
* the 64-bit registers of the Intel architecture (e.g., rax instead of eax).
|
||||
|
@ -65,7 +59,7 @@ class CMipsMemoryVM :
|
|||
private CDMA
|
||||
{
|
||||
public:
|
||||
CMipsMemoryVM(CMipsMemory_CallBack * CallBack, bool SavesReadOnly);
|
||||
CMipsMemoryVM(bool SavesReadOnly);
|
||||
~CMipsMemoryVM();
|
||||
|
||||
static void ReserveMemory();
|
||||
|
@ -208,8 +202,6 @@ private:
|
|||
static void Write32CartridgeDomain2Address2(void);
|
||||
static void Write32PifRam(void);
|
||||
|
||||
CMipsMemory_CallBack * const m_CBClass;
|
||||
|
||||
//Memory Locations
|
||||
static uint8_t * m_Reserve1, *m_Reserve2;
|
||||
uint8_t * m_RDRAM, *m_DMEM, *m_IMEM;
|
||||
|
|
|
@ -34,7 +34,7 @@ m_SaveUsing((SAVE_CHIP_TYPE)g_Settings->LoadDword(Game_SaveChip)),
|
|||
m_Plugins(Plugins),
|
||||
m_SyncCPU(NULL),
|
||||
m_SyncPlugins(NULL),
|
||||
m_MMU_VM(this, SavesReadOnly),
|
||||
m_MMU_VM(SavesReadOnly),
|
||||
m_TLB(this),
|
||||
m_Reg(this, this),
|
||||
m_Recomp(NULL),
|
||||
|
@ -1912,19 +1912,6 @@ void CN64System::RefreshScreen()
|
|||
// if (bProfiling) { m_Profile.StartTimer(ProfilingAddr != Timer_None ? ProfilingAddr : Timer_R4300); }
|
||||
}
|
||||
|
||||
bool CN64System::WriteToProtectedMemory(uint32_t Address, int length)
|
||||
{
|
||||
WriteTrace(TraceN64System, TraceDebug, "Address: %X Len: %d", Address, length);
|
||||
if (m_Recomp)
|
||||
{
|
||||
g_Notify->BreakPoint(__FILE__, __LINE__);
|
||||
#ifdef tofix
|
||||
return m_Recomp->ClearRecompCode_Phys(Address, length, CRecompiler::Remove_ProtectedMem);
|
||||
#endif
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
void CN64System::TLB_Mapped(uint32_t VAddr, uint32_t Len, uint32_t PAddr, bool bReadOnly)
|
||||
{
|
||||
m_MMU_VM.TLB_Mapped(VAddr, Len, PAddr, bReadOnly);
|
||||
|
|
|
@ -12,6 +12,7 @@
|
|||
|
||||
#include <Common/SyncEvent.h>
|
||||
#include <Project64-core/Settings/N64SystemSettings.h>
|
||||
#include <Project64-core/N64System/ProfilingClass.h>
|
||||
#include <Project64-core/N64System/Recompiler/RecompilerClass.h>
|
||||
#include <Project64-core/N64System/Mips/MemoryVirtualMem.h>
|
||||
#include <Project64-core/Settings/DebugSettings.h>
|
||||
|
@ -23,7 +24,6 @@
|
|||
#include "Mips/TLBClass.h"
|
||||
#include "Mips/Audio.h"
|
||||
#include "Mips/SystemTiming.h"
|
||||
#include "ProfilingClass.h"
|
||||
#include "CheatClass.h"
|
||||
#include "FramePerSecondClass.h"
|
||||
#include "SpeedLimiterClass.h"
|
||||
|
@ -40,7 +40,6 @@ class CRecompiler;
|
|||
|
||||
class CN64System :
|
||||
public CLogging,
|
||||
public CMipsMemory_CallBack,
|
||||
public CTLB_CB,
|
||||
private CSystemEvents,
|
||||
protected CN64SystemSettings,
|
||||
|
@ -129,17 +128,14 @@ private:
|
|||
//Mark information saying that the CPU has stopped
|
||||
void CpuStopped();
|
||||
|
||||
//Function in CMipsMemory_CallBack
|
||||
virtual bool WriteToProtectedMemory(uint32_t Address, int32_t length);
|
||||
|
||||
//Functions in CTLB_CB
|
||||
void TLB_Mapped(uint32_t VAddr, uint32_t Len, uint32_t PAddr, bool bReadOnly);
|
||||
void TLB_Unmaped(uint32_t VAddr, uint32_t Len);
|
||||
void TLB_Changed();
|
||||
|
||||
CPlugins * const m_Plugins; //The plugin container
|
||||
CN64System * m_SyncCPU;
|
||||
CPlugins * m_SyncPlugins;
|
||||
CN64System * m_SyncCPU;
|
||||
CMipsMemoryVM m_MMU_VM; //Memory of the n64
|
||||
CTLB m_TLB;
|
||||
CRegisters m_Reg;
|
||||
|
|
Loading…
Reference in New Issue