fix regression with interrupts

This commit is contained in:
hap 2015-05-26 09:25:45 +02:00
parent c5b5e9ac13
commit a4f6a78d7f

View File

@ -557,18 +557,18 @@ void hmcs40_cpu_device::execute_run()
if ((m_prev_op & 0x3e0) == 0x340)
m_pc = ((m_page << 6) | (m_pc & 0x3f)) & m_pcmask;
// remember previous state
m_prev_op = m_op;
m_prev_pc = m_pc;
// check/handle interrupt, but not in the middle of a long jump
if (m_ie && (m_iri || m_irt) && (m_op & 0x3e0) != 0x340)
if (m_ie && (m_iri || m_irt) && (m_prev_op & 0x3e0) != 0x340)
{
do_interrupt();
if (m_icount <= 0)
break;
}
// remember previous state
m_prev_op = m_op;
m_prev_pc = m_pc;
// fetch next opcode
debugger_instruction_hook(this, m_pc);
m_icount--;