tracer: use .log extention (allows extension based user syntax highlight)
genesis disasm: prefix immediate values with #.
This commit is contained in:
parent
e9225089d6
commit
c41c24cd85
|
@ -198,7 +198,7 @@ namespace BizHawk.Client.EmuHawk
|
|||
var sfd = new SaveFileDialog();
|
||||
if (_logFile == null)
|
||||
{
|
||||
sfd.FileName = PathManager.FilesystemSafeName(Global.Game) + ".txt";
|
||||
sfd.FileName = PathManager.FilesystemSafeName(Global.Game) + ".log";
|
||||
sfd.InitialDirectory = PathManager.MakeAbsolutePath(Global.Config.PathEntries.LogPathFragment, null);
|
||||
}
|
||||
else if (!string.IsNullOrWhiteSpace(_logFile.FullName))
|
||||
|
|
|
@ -89,8 +89,8 @@ namespace BizHawk.Emulation.Cores.Components.M68000
|
|||
else if (Opcodes[op] == CMP) CMP_Disasm(info);
|
||||
else if (Opcodes[op] == CMPM) CMPM_Disasm(info);
|
||||
else if (Opcodes[op] == CMPA) CMPA_Disasm(info);
|
||||
|
||||
else if (Opcodes[op] == CMPI) CMPI_Disasm(info);
|
||||
|
||||
else if (Opcodes[op] == MULU) MULU_Disasm(info);
|
||||
else if (Opcodes[op] == MULS) MULS_Disasm(info);
|
||||
else if (Opcodes[op] == DIVU) DIVU_Disasm(info);
|
||||
|
|
|
@ -200,7 +200,7 @@ namespace BizHawk.Emulation.Cores.Components.M68000
|
|||
{
|
||||
info.Mnemonic = "andi.b";
|
||||
sbyte imm = (sbyte)ReadWord(pc); pc += 2;
|
||||
info.Args = string.Format("${0:X}, ", imm);
|
||||
info.Args = string.Format("#${0:X}, ", imm);
|
||||
info.Args += DisassembleValue(dstMode, dstReg, 1, ref pc);
|
||||
break;
|
||||
}
|
||||
|
@ -208,7 +208,7 @@ namespace BizHawk.Emulation.Cores.Components.M68000
|
|||
{
|
||||
info.Mnemonic = "andi.w";
|
||||
short imm = ReadWord(pc); pc += 2;
|
||||
info.Args = string.Format("${0:X}, ", imm);
|
||||
info.Args = string.Format("#${0:X}, ", imm);
|
||||
info.Args += DisassembleValue(dstMode, dstReg, 2, ref pc);
|
||||
break;
|
||||
}
|
||||
|
@ -216,7 +216,7 @@ namespace BizHawk.Emulation.Cores.Components.M68000
|
|||
{
|
||||
info.Mnemonic = "andi.l";
|
||||
int imm = ReadLong(pc); pc += 4;
|
||||
info.Args = string.Format("${0:X}, ", imm);
|
||||
info.Args = string.Format("#${0:X}, ", imm);
|
||||
info.Args += DisassembleValue(dstMode, dstReg, 4, ref pc);
|
||||
break;
|
||||
}
|
||||
|
@ -355,21 +355,21 @@ namespace BizHawk.Emulation.Cores.Components.M68000
|
|||
{
|
||||
info.Mnemonic = "eori.b";
|
||||
sbyte immed = (sbyte)ReadWord(pc); pc += 2;
|
||||
info.Args = String.Format("${0:X}, {1}", immed, DisassembleValue(mode, reg, 1, ref pc));
|
||||
info.Args = String.Format("#${0:X}, {1}", immed, DisassembleValue(mode, reg, 1, ref pc));
|
||||
break;
|
||||
}
|
||||
case 1: // word
|
||||
{
|
||||
info.Mnemonic = "eori.w";
|
||||
short immed = ReadWord(pc); pc += 2;
|
||||
info.Args = String.Format("${0:X}, {1}", immed, DisassembleValue(mode, reg, 2, ref pc));
|
||||
info.Args = String.Format("#${0:X}, {1}", immed, DisassembleValue(mode, reg, 2, ref pc));
|
||||
break;
|
||||
}
|
||||
case 2: // long
|
||||
{
|
||||
info.Mnemonic = "eori.l";
|
||||
int immed = ReadLong(pc); pc += 4;
|
||||
info.Args = String.Format("${0:X}, {1}", immed, DisassembleValue(mode, reg, 4, ref pc));
|
||||
info.Args = String.Format("#${0:X}, {1}", immed, DisassembleValue(mode, reg, 4, ref pc));
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
@ -568,21 +568,21 @@ namespace BizHawk.Emulation.Cores.Components.M68000
|
|||
{
|
||||
info.Mnemonic = "ori.b";
|
||||
sbyte immed = (sbyte)ReadWord(pc); pc += 2;
|
||||
info.Args = String.Format("${0:X}, {1}", immed, DisassembleValue(mode, reg, 1, ref pc));
|
||||
info.Args = String.Format("#${0:X}, {1}", immed, DisassembleValue(mode, reg, 1, ref pc));
|
||||
break;
|
||||
}
|
||||
case 1: // word
|
||||
{
|
||||
info.Mnemonic = "ori.w";
|
||||
short immed = ReadWord(pc); pc += 2;
|
||||
info.Args = String.Format("${0:X}, {1}", immed, DisassembleValue(mode, reg, 2, ref pc));
|
||||
info.Args = String.Format("#${0:X}, {1}", immed, DisassembleValue(mode, reg, 2, ref pc));
|
||||
break;
|
||||
}
|
||||
case 2: // long
|
||||
{
|
||||
info.Mnemonic = "ori.l";
|
||||
int immed = ReadLong(pc); pc += 4;
|
||||
info.Args = String.Format("${0:X}, {1}", immed, DisassembleValue(mode, reg, 4, ref pc));
|
||||
info.Args = String.Format("#${0:X}, {1}", immed, DisassembleValue(mode, reg, 4, ref pc));
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1001,17 +1001,17 @@ namespace BizHawk.Emulation.Cores.Components.M68000
|
|||
case 0:
|
||||
immediate = (byte)ReadWord(pc); pc += 2;
|
||||
info.Mnemonic = "cmpi.b";
|
||||
info.Args = String.Format("${0:X}, {1}", immediate, DisassembleValue(mode, reg, 1, ref pc));
|
||||
info.Args = String.Format("#${0:X}, {1}", immediate, DisassembleValue(mode, reg, 1, ref pc));
|
||||
break;
|
||||
case 1:
|
||||
immediate = ReadWord(pc); pc += 2;
|
||||
info.Mnemonic = "cmpi.w";
|
||||
info.Args = String.Format("${0:X}, {1}", immediate, DisassembleValue(mode, reg, 2, ref pc));
|
||||
info.Args = String.Format("#${0:X}, {1}", immediate, DisassembleValue(mode, reg, 2, ref pc));
|
||||
break;
|
||||
case 2:
|
||||
immediate = ReadLong(pc); pc += 4;
|
||||
info.Mnemonic = "cmpi.l";
|
||||
info.Args = String.Format("${0:X}, {1}", immediate, DisassembleValue(mode, reg, 4, ref pc));
|
||||
info.Args = String.Format("#${0:X}, {1}", immediate, DisassembleValue(mode, reg, 4, ref pc));
|
||||
break;
|
||||
}
|
||||
info.Length = pc - info.PC;
|
||||
|
|
|
@ -319,7 +319,7 @@ namespace BizHawk.Emulation.Cores.Components.M68000
|
|||
int reg = op & 7;
|
||||
|
||||
info.Mnemonic = "btst";
|
||||
info.Args = String.Format("${0:X}, {1}", bit, DisassembleValue(mode, reg, 1, ref pc));
|
||||
info.Args = String.Format("#${0:X}, {1}", bit, DisassembleValue(mode, reg, 1, ref pc));
|
||||
info.Length = pc - info.PC;
|
||||
}
|
||||
|
||||
|
@ -392,7 +392,7 @@ namespace BizHawk.Emulation.Cores.Components.M68000
|
|||
int reg = op & 7;
|
||||
|
||||
info.Mnemonic = "bchg";
|
||||
info.Args = String.Format("${0:X}, {1}", bit, DisassembleValue(mode, reg, 1, ref pc));
|
||||
info.Args = String.Format("#${0:X}, {1}", bit, DisassembleValue(mode, reg, 1, ref pc));
|
||||
info.Length = pc - info.PC;
|
||||
}
|
||||
|
||||
|
@ -469,7 +469,7 @@ namespace BizHawk.Emulation.Cores.Components.M68000
|
|||
int reg = op & 7;
|
||||
|
||||
info.Mnemonic = "bclr";
|
||||
info.Args = String.Format("${0:X}, {1}", bit, DisassembleValue(mode, reg, 1, ref pc));
|
||||
info.Args = String.Format("#${0:X}, {1}", bit, DisassembleValue(mode, reg, 1, ref pc));
|
||||
info.Length = pc - info.PC;
|
||||
}
|
||||
|
||||
|
@ -546,7 +546,7 @@ namespace BizHawk.Emulation.Cores.Components.M68000
|
|||
int reg = op & 7;
|
||||
|
||||
info.Mnemonic = "bset";
|
||||
info.Args = String.Format("${0:X}, {1}", bit, DisassembleValue(mode, reg, 1, ref pc));
|
||||
info.Args = String.Format("#${0:X}, {1}", bit, DisassembleValue(mode, reg, 1, ref pc));
|
||||
info.Length = pc - info.PC;
|
||||
}
|
||||
|
||||
|
|
|
@ -146,7 +146,7 @@ namespace BizHawk.Emulation.Cores.Components.M68000
|
|||
void TRAP_Disasm(DisassemblyInfo info)
|
||||
{
|
||||
info.Mnemonic = "trap";
|
||||
info.Args = string.Format("${0:X}", op & 0xF);
|
||||
info.Args = string.Format("#${0:X}", op & 0xF);
|
||||
}
|
||||
|
||||
void TrapVector(int vector)
|
||||
|
|
|
@ -359,13 +359,13 @@ namespace BizHawk.Emulation.Cores.Components.M68000
|
|||
{
|
||||
case 1:
|
||||
immed = (byte)ReadWord(pc); pc += 2;
|
||||
return String.Format("${0:X}", immed);
|
||||
return String.Format("#${0:X}", immed);
|
||||
case 2:
|
||||
immed = (ushort)ReadWord(pc); pc += 2;
|
||||
return String.Format("${0:X}", immed);
|
||||
return String.Format("#${0:X}", immed);
|
||||
case 4:
|
||||
immed = ReadLong(pc); pc += 4;
|
||||
return String.Format("${0:X}", immed);
|
||||
return String.Format("#${0:X}", immed);
|
||||
}
|
||||
throw new ArgumentException("Invalid size");
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue