summaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
author Robbbert <Robbbert@users.noreply.github.com>2022-05-25 13:09:36 +1000
committer Robbbert <Robbbert@users.noreply.github.com>2022-05-25 13:09:36 +1000
commit6e688ce48e5f6cf470ff8b28cb8b0b2e0df7cb0a (patch)
treea81c546b1fff91f2f4306aa8ab1f2686b6f92461
parentf383ae926d3efff1af7e7ddff0cee28b9e18149b (diff)
pps4: new variables need to be saved.
-rw-r--r--src/devices/cpu/pps4/pps4.cpp10
-rw-r--r--src/devices/cpu/pps4/pps4.h1
2 files changed, 4 insertions, 7 deletions
diff --git a/src/devices/cpu/pps4/pps4.cpp b/src/devices/cpu/pps4/pps4.cpp
index 6b3c3c7ea20..1a44fa2a39b 100644
--- a/src/devices/cpu/pps4/pps4.cpp
+++ b/src/devices/cpu/pps4/pps4.cpp
@@ -155,7 +155,6 @@ std::unique_ptr<util::disasm_interface> pps4_device::create_disassembler()
inline u8 pps4_device::ROP()
{
const u8 op = m_cache.read_byte(m_P & 0xFFF);
- m_Ip = m_I1; // save previous opcode
m_P = (m_P + 1) & 0xFFF;
m_icount -= 1;
return op;
@@ -1573,7 +1572,8 @@ void pps4_device::device_start()
save_item(NAME(m_FF2));
save_item(NAME(m_I1));
save_item(NAME(m_I2));
- save_item(NAME(m_Ip));
+ save_item(NAME(m_wasldi));
+ save_item(NAME(m_waslbl));
state_add( PPS4_PC, "PC", m_P ).mask(0xFFF).formatstr("%03X");
state_add( PPS4_A, "A", m_A ).formatstr("%01X");
@@ -1585,7 +1585,6 @@ void pps4_device::device_start()
state_add( PPS4_B, "B", m_B ).formatstr("%03X");
state_add( PPS4_I1, "I1", m_I1 ).formatstr("%02X").noshow();
state_add( PPS4_I2, "I2", m_I2 ).formatstr("%02X").noshow();
- state_add( PPS4_Ip, "Ip", m_Ip ).formatstr("%02X").noshow();
state_add( STATE_GENPC, "GENPC", m_P ).noshow();
state_add( STATE_GENPCBASE,"CURPC", m_P ).noshow();
state_add( STATE_GENFLAGS, "GENFLAGS", m_C).formatstr("%3s").noshow();
@@ -1634,9 +1633,8 @@ void pps4_device::device_reset()
m_FF2 = 0; // Flip-flop 2
m_I1 = 0; // Most recent instruction I(8:1)
m_I2 = 0; // Most recent parameter I2(8:1)
- m_Ip = 0; // Previous instruction I(8:1)
- m_wasldi = 0;
- m_waslbl = 0;
+ m_wasldi = 0; // was last instruction LDI?
+ m_waslbl = 0; // was last instruction LB/LBL?
}
void pps4_2_device::device_reset()
diff --git a/src/devices/cpu/pps4/pps4.h b/src/devices/cpu/pps4/pps4.h
index 6cdc7799343..4b9b82f37c0 100644
--- a/src/devices/cpu/pps4/pps4.h
+++ b/src/devices/cpu/pps4/pps4.h
@@ -100,7 +100,6 @@ protected:
u8 m_FF2; //!< Flip-flop 2
u8 m_I1; //!< Most recent instruction I(8:1)
u8 m_I2; //!< Most recent parameter I2(8:1)
- u8 m_Ip; //!< Previous instruction I(8:1)
//! return memory at address B(12:1)
inline u8 M();