public MIPSEvaluator(ROMHandler.ROMHandler rom, ROMHandler.DMATableEntry dma, uint ramadr, RegisterHookDelegate reghook = null, ushort var = 0) { BaseAddress = ramadr; Registers = new uint[32]; Stack = new uint[256 * MIPS.SafetyVal]; StackPos = (int)(128 * MIPS.SafetyVal); Sections = new OvlSections(rom, dma, 0); MemoryMap = new List <MemoryRegion>(); MemoryMap.Add(new MemoryRegion(Sections.text, ramadr + Sections.textVA)); MemoryMap.Add(new MemoryRegion(Sections.data, ramadr + Sections.dataVA)); MemoryMap.Add(new MemoryRegion(Sections.rodata, ramadr + Sections.rodataVA)); MemoryMap.Add(new MemoryRegion(Sections.bss, ramadr + Sections.bssVA)); RegisterHook = reghook; SpecialOps = new List <SpecialOp>(); SpecialOps.Add(new SpecialOp(MIPS.LH((uint)MIPS.Register.R0, 0x1C, (uint)MIPS.Register.A0), MIPS.LH((uint)MIPS.Register.R0, 0x1C, (uint)MIPS.Register.A0), var)); SpecialOps.Add(new SpecialOp(MIPS.LH((uint)MIPS.Register.R0, 0x1C, (uint)MIPS.Register.S0), MIPS.LH((uint)MIPS.Register.R0, 0x1C, (uint)MIPS.Register.A0), var)); Watches = new List <uint>(); }
public MIPSEvaluator(ROMHandler.ROMHandler rom, ROMHandler.DMATableEntry dma, uint ramadr, RegisterHookDelegate reghook = null, ushort var = 0) { BaseAddress = ramadr; Registers = new uint[32]; Stack = new uint[256 * MIPS.SafetyVal]; StackPos = (int)(128 * MIPS.SafetyVal); Sections = new OvlSections(rom, dma, 0); MemoryMap = new List<MemoryRegion>(); MemoryMap.Add(new MemoryRegion(Sections.text, ramadr + Sections.textVA)); MemoryMap.Add(new MemoryRegion(Sections.data, ramadr + Sections.dataVA)); MemoryMap.Add(new MemoryRegion(Sections.rodata, ramadr + Sections.rodataVA)); MemoryMap.Add(new MemoryRegion(Sections.bss, ramadr + Sections.bssVA)); RegisterHook = reghook; SpecialOps = new List<SpecialOp>(); SpecialOps.Add(new SpecialOp(MIPS.LH((uint)MIPS.Register.R0, 0x1C, (uint)MIPS.Register.A0), MIPS.LH((uint)MIPS.Register.R0, 0x1C, (uint)MIPS.Register.A0), var)); SpecialOps.Add(new SpecialOp(MIPS.LH((uint)MIPS.Register.R0, 0x1C, (uint)MIPS.Register.S0), MIPS.LH((uint)MIPS.Register.R0, 0x1C, (uint)MIPS.Register.A0), var)); Watches = new List<uint>(); }