mirror of
https://github.com/holub/mame
synced 2025-04-19 15:11:37 +03:00
hmcs40: Workaround related to MT #6638; this disables a poorly implemented disassembly feature to prevent assertion failures and crashes when debugging drivers using HD44801 (nw)
This commit is contained in:
parent
8a1ba16a8f
commit
46a221b95e
@ -81,6 +81,7 @@ static const u32 s_flags[] =
|
||||
0
|
||||
};
|
||||
|
||||
#ifdef COMPUTE_NEXT_PC
|
||||
// next program counter in sequence (relative)
|
||||
static const s8 s_next_pc[0x40] =
|
||||
{
|
||||
@ -89,6 +90,7 @@ static const s8 s_next_pc[0x40] =
|
||||
-32, -31, -30, -29, -28, -27, -26, -25, -24, -23, -22, -21, -20, -19, -18, -17,
|
||||
-15, -14, -13, -12, -11, -10, -9, -8, -7, -6, -5, -4, -3, -2, -1, -1
|
||||
};
|
||||
#endif
|
||||
|
||||
|
||||
static const u8 hmcs40_mnemonic[0x400] =
|
||||
@ -226,6 +228,11 @@ CPU_DISASSEMBLE(hmcs40)
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef COMPUTE_NEXT_PC
|
||||
// falsifying instruction lengths like this breaks the MAME disassembler quite badly
|
||||
int pos = s_next_pc[pc & 0x3f] & DASMFLAG_LENGTHMASK;
|
||||
return pos | s_flags[instr] | DASMFLAG_SUPPORTED;
|
||||
#else
|
||||
return 1 | s_flags[instr] | DASMFLAG_SUPPORTED;
|
||||
#endif
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user