summaryrefslogtreecommitdiffstatshomepage
path: root/src/devices/cpu/z8/z8.cpp
diff options
context:
space:
mode:
author smf- <smf-@users.noreply.github.com>2016-09-27 14:24:33 +0100
committer smf- <smf-@users.noreply.github.com>2016-09-27 14:26:27 +0100
commit1a186c8a3a16a7ce99d7df2dd217a7552b696c92 (patch)
treedb6f7a7442ccc924049e3354c8cded6d62071ecd /src/devices/cpu/z8/z8.cpp
parent3957d89e4466d87f86a42597a49db12a7c040520 (diff)
Make sure all cpu's export STATE_GENPCBASE and use safe_pcbase() for everything in the debugger, which allows interruptible cpu's to work properly. [smf]
Diffstat (limited to 'src/devices/cpu/z8/z8.cpp')
-rw-r--r--src/devices/cpu/z8/z8.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/devices/cpu/z8/z8.cpp b/src/devices/cpu/z8/z8.cpp
index 53aecb48b1b..7e21e5d2e5b 100644
--- a/src/devices/cpu/z8/z8.cpp
+++ b/src/devices/cpu/z8/z8.cpp
@@ -670,6 +670,7 @@ void z8_device::device_start()
{
state_add(Z8_PC, "PC", m_pc);
state_add(STATE_GENPC, "GENPC", m_pc).noshow();
+ state_add(STATE_GENPCBASE, "CURPC", m_pc).noshow();
state_add(Z8_SP, "SP", m_fake_sp).callimport().callexport();
state_add(STATE_GENSP, "GENSP", m_fake_sp).callimport().callexport().noshow();
state_add(Z8_RP, "RP", m_r[Z8_REGISTER_RP]);
@@ -773,7 +774,7 @@ void z8_device::state_import(const device_state_entry &entry)
switch (entry.index())
{
case Z8_SP:
- case Z8_GENSP:
+ case STATE_GENSP:
m_r[Z8_REGISTER_SPH] = m_fake_sp >> 8;
m_r[Z8_REGISTER_SPL] = m_fake_sp & 0xff;
break;
@@ -792,7 +793,7 @@ void z8_device::state_export(const device_state_entry &entry)
switch (entry.index())
{
case Z8_SP:
- case Z8_GENSP:
+ case STATE_GENSP:
m_fake_sp = (m_r[Z8_REGISTER_SPH] << 8) | m_r[Z8_REGISTER_SPL];
break;