summaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
author AJR <ajrhacker@users.noreply.github.com>2021-04-19 15:44:17 -0400
committer AJR <ajrhacker@users.noreply.github.com>2021-04-19 15:44:17 -0400
commit4b47c9f10218f306b11f2bea07623728574a625e (patch)
tree5919b44872299462c2b2e9d37095e82b5fa3722c
parent462f71aa7b74aba9aa7954077241c4155433345d (diff)
mn1860: Identify another 2 opcodes in disassembly
-rw-r--r--src/devices/cpu/mn1880/mn1880d.cpp18
1 files changed, 14 insertions, 4 deletions
diff --git a/src/devices/cpu/mn1880/mn1880d.cpp b/src/devices/cpu/mn1880/mn1880d.cpp
index bce7217b362..1064137f86a 100644
--- a/src/devices/cpu/mn1880/mn1880d.cpp
+++ b/src/devices/cpu/mn1880/mn1880d.cpp
@@ -157,8 +157,8 @@ const char *const mn1860_disassembler::s_inst_names[256] =
"call", "call", "call", "call", "call", "call", "call", "call",
"br", "br", "br", "br", "br", "br", "br", "br",
"br", "br", "br", "br", "br", "br", "br", "br",
- nullptr, "pop", nullptr, "pop", "pop", "pop", "pop", "pop",
- nullptr, "push", nullptr, "push", "push", "push", "push", "push",
+ nullptr, "pop", "divl", "pop", "pop", "pop", "pop", "pop",
+ nullptr, "push", "mull", "push", "push", "push", "push", "push",
"subcl", "div", "subcl", "subcl", "xch", "xch", "xch", "xch",
"addcl", "mul", "addcl", "addcl", "mov", "mov", "mov", "mov",
"cmp", "cmp", "cmp", "cmp", "xch", "xch", nullptr, "xch",
@@ -303,7 +303,7 @@ void mn1880_disassembler::dasm_operands(std::ostream &stream, u8 opcode, offs_t
stream << ", ";
format_imm(stream, opcodes.r8(pc++));
}
- else if (opcode < 0x50 || (opcode & 0xf7) == 0xb5 || ((opcode & 0xf7) == 0xc3 && m_inst_names[opcode][4] == 0))
+ else if (opcode < 0x50 || (opcode & 0xf7) == 0xb5 || ((opcode & 0xf7) == 0xc3 && m_inst_names[opcode][4] == '\0'))
{
// Unary operations
if (BIT(opcode, 0))
@@ -428,7 +428,7 @@ void mn1880_disassembler::dasm_operands(std::ostream &stream, u8 opcode, offs_t
{
if (BIT(opcode, 0))
stream << "fs";
- else
+ else if (m_inst_names[opcode][0] == 't' || m_inst_names[opcode][3] == '\0')
{
// CLR, SET, T1BNZ, T1BZ indirect (MN1870 only)
format_indirect_bp(stream, "xp", opcodes.r8(pc++) & 0x07);
@@ -439,6 +439,16 @@ void mn1880_disassembler::dasm_operands(std::ostream &stream, u8 opcode, offs_t
++pc;
}
}
+ else
+ {
+ // 3 direct operands? (MN1880 only)
+ format_direct(stream, opcodes.r8(pc + 2));
+ stream << ", ";
+ format_direct(stream, opcodes.r8(pc));
+ stream << ", ";
+ format_direct(stream, opcodes.r8(pc + 1));
+ pc += 3;
+ }
}
else if (opcode < 0xc0 || (opcode & 0xfc) == 0xe4 || (opcode & 0xfe) == 0xfc)
{