n64: use traditional GPR names for debugger too
This commit is contained in:
parent
3a75fe412f
commit
9d4ba478ce
|
@ -19,8 +19,8 @@ namespace BizHawk.Emulation.Cores.Nintendo.N64
|
|||
for (int i = 0; i < 32; i++)
|
||||
{
|
||||
var reg = BitConverter.ToInt64(data, i * 8);
|
||||
ret.Add("REG" + i + "_lo", (int)(reg));
|
||||
ret.Add("REG" + i + "_hi", (int)(reg >> 32));
|
||||
ret.Add(GPRnames[i] + "_lo", (int)(reg));
|
||||
ret.Add(GPRnames[i] + "_hi", (int)(reg >> 32));
|
||||
}
|
||||
|
||||
var PC = BitConverter.ToUInt32(data, 32 * 8);
|
||||
|
@ -55,6 +55,22 @@ namespace BizHawk.Emulation.Cores.Nintendo.N64
|
|||
return ret;
|
||||
}
|
||||
|
||||
public string[] GPRnames = new string[32]
|
||||
{
|
||||
"r0",
|
||||
"at",
|
||||
"v0", "v1",
|
||||
"a0", "a1", "a2", "a3",
|
||||
"t0", "t1", "t2", "t3", "t4", "t5", "t6", "t7",
|
||||
"s0", "s1", "s2", "s3", "s4", "s5", "s6", "s7",
|
||||
"t8", "t9",
|
||||
"k0", "k1",
|
||||
"gp",
|
||||
"sp",
|
||||
"s8",
|
||||
"ra"
|
||||
};
|
||||
|
||||
[FeatureNotImplemented]
|
||||
public void SetCpuRegister(string register, int value)
|
||||
{
|
||||
|
|
|
@ -30,7 +30,7 @@ namespace BizHawk.Emulation.Cores.Nintendo.N64
|
|||
|
||||
for (int i = 1; i < 32; i++) // r0 is always zero
|
||||
{
|
||||
UInt64 val = (regs["REG" + i + "_hi"].Value << 32) | regs["REG" + i + "_lo"].Value;
|
||||
UInt64 val = (regs[GPRnames[i] + "_hi"].Value << 32) | regs[GPRnames[i] + "_lo"].Value;
|
||||
string name = GPRnames[i];
|
||||
sb.Append(string.Format("{0}:{1:X16} ", name, val));
|
||||
}
|
||||
|
@ -62,21 +62,5 @@ namespace BizHawk.Emulation.Cores.Nintendo.N64
|
|||
(ServiceProvider as BasicServiceProvider).Register<ITraceable>(Tracer);
|
||||
_tracecb = new mupen64plusApi.TraceCallback(MakeTrace);
|
||||
}
|
||||
|
||||
private string[] GPRnames = new string[32]
|
||||
{
|
||||
"r0",
|
||||
"at",
|
||||
"v0", "v1",
|
||||
"a0", "a1", "a2", "a3",
|
||||
"t0", "t1", "t2", "t3", "t4", "t5", "t6", "t7",
|
||||
"s0", "s1", "s2", "s3", "s4", "s5", "s6", "s7",
|
||||
"t8", "t9",
|
||||
"k0", "k1",
|
||||
"gp",
|
||||
"sp",
|
||||
"s8",
|
||||
"ra"
|
||||
};
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue