summaryrefslogtreecommitdiffstatshomepage
path: root/src/emu/cpu/pdp1
diff options
context:
space:
mode:
author Aaron Giles <aaron@aarongiles.com>2012-09-11 15:58:04 +0000
committer Aaron Giles <aaron@aarongiles.com>2012-09-11 15:58:04 +0000
commit0aa418e85b7f7aad5088bc96c9da0c371b15b2f2 (patch)
treee13bbdf8a2ff82faf97aaa23351668d817628966 /src/emu/cpu/pdp1
parent6d8c3c9f2d5d30848751a12c2925fbe53ac8bfec (diff)
In device_state_interface, rename state() to state_int()
and set_state() to set_state_int() for consistency. Update all callers. Also add set_pc() helper and updated all callers to use that instead of set_state_int(STATE_GENPC) [Aaron Giles] Added device_t::state() method to get the state interface. Added redundant device_state_interface::state() method to catch redundant use of it. [Aaron Giles] Removed cpu_get_reg() and cpu_set_reg() macros in favor of using the above methods. [Aaron Giles]
Diffstat (limited to 'src/emu/cpu/pdp1')
-rw-r--r--src/emu/cpu/pdp1/pdp1.c2
-rw-r--r--src/emu/cpu/pdp1/pdp1.h4
-rw-r--r--src/emu/cpu/pdp1/tx0.h4
3 files changed, 5 insertions, 5 deletions
diff --git a/src/emu/cpu/pdp1/pdp1.c b/src/emu/cpu/pdp1/pdp1.c
index f2e68e67609..e5c37532c87 100644
--- a/src/emu/cpu/pdp1/pdp1.c
+++ b/src/emu/cpu/pdp1/pdp1.c
@@ -1707,7 +1707,7 @@ static void null_iot(device_t *device, int op2, int nac, int mb, int *io, int ac
if (LOG_IOT_EXTRA)
{
if (op2 == 000)
- logerror("IOT sync instruction: mb=0%06o, pc=0%06o\n", (unsigned) mb, (unsigned) cpu_get_reg(device, PDP1_PC));
+ logerror("IOT sync instruction: mb=0%06o, pc=0%06o\n", (unsigned) mb, (unsigned) device->state().state_int(PDP1_PC));
}
if (LOG)
{
diff --git a/src/emu/cpu/pdp1/pdp1.h b/src/emu/cpu/pdp1/pdp1.h
index 7e31766b209..ddf6d9b2fe5 100644
--- a/src/emu/cpu/pdp1/pdp1.h
+++ b/src/emu/cpu/pdp1/pdp1.h
@@ -19,8 +19,8 @@ enum
PDP1_IO_COMPLETE /* hack, do not use directly, use pdp1_pulse_iot_done instead */
};
-#define pdp1_pulse_start_clear(cpudevice) cpu_set_reg(cpudevice, PDP1_START_CLEAR, (UINT64)0)
-#define pdp1_pulse_iot_done(cpudevice) cpu_set_reg(cpudevice, PDP1_IO_COMPLETE, (UINT64)0)
+#define pdp1_pulse_start_clear(cpudevice) (cpudevice)->state().set_state_int(PDP1_START_CLEAR, (UINT64)0)
+#define pdp1_pulse_iot_done(cpudevice) (cpudevice)->state().set_state_int(PDP1_IO_COMPLETE, (UINT64)0)
typedef void (*pdp1_extern_iot_func)(device_t *device, int op2, int nac, int mb, int *io, int ac);
typedef void (*pdp1_read_binary_word_func)(device_t *device);
diff --git a/src/emu/cpu/pdp1/tx0.h b/src/emu/cpu/pdp1/tx0.h
index d36c48082e0..3e94f8f5a0b 100644
--- a/src/emu/cpu/pdp1/tx0.h
+++ b/src/emu/cpu/pdp1/tx0.h
@@ -20,8 +20,8 @@ enum
TX0_IO_COMPLETE /* hack, do not use directly, use tx0_pulse_io_complete instead */
};
-#define tx0_pulse_reset(cpudevice) cpu_set_reg(cpudevice, TX0_RESET, 0)
-#define tx0_pulse_io_complete(cpudevice) cpu_set_reg(cpudevice, TX0_IO_COMPLETE, 0)
+#define tx0_pulse_reset(cpudevice) (cpudevice)->state().set_state_int(TX0_RESET, 0)
+#define tx0_pulse_io_complete(cpudevice) (cpudevice)->state().set_state_int(TX0_IO_COMPLETE, 0)
typedef struct _tx0_reset_param_t tx0_reset_param_t;
struct _tx0_reset_param_t