mirror of
https://github.com/holub/mame
synced 2025-04-23 00:39:36 +03:00
m68000: Don't iterate to save arrays; eliiminate legacy prepost registration (nw)
This commit is contained in:
parent
cc093aaf50
commit
da117d528b
@ -128,9 +128,6 @@ protected:
|
||||
static void m68ki_set_one(unsigned short opcode, u16 state, const opcode_handler_struct &s);
|
||||
static void m68ki_build_opcode_table(void);
|
||||
|
||||
void presave();
|
||||
void postload();
|
||||
|
||||
void clear_all(void);
|
||||
|
||||
// device_disasm_interface overrides
|
||||
@ -148,6 +145,8 @@ protected:
|
||||
virtual void device_start() override;
|
||||
virtual void device_reset() override;
|
||||
virtual void device_stop() override;
|
||||
virtual void device_pre_save() override;
|
||||
virtual void device_post_load() override;
|
||||
|
||||
// device_memory_interface overrides
|
||||
virtual space_config_vector memory_space_config() const override;
|
||||
|
@ -735,14 +735,14 @@ void m68000_base_device::set_irq_line(int irqline, int state)
|
||||
m_nmi_pending = true;
|
||||
}
|
||||
|
||||
void m68000_base_device::presave()
|
||||
void m68000_base_device::device_pre_save()
|
||||
{
|
||||
m_save_sr = m68ki_get_sr();
|
||||
m_save_stopped = (m_stopped & STOP_LEVEL_STOP) != 0;
|
||||
m_save_halted = (m_stopped & STOP_LEVEL_HALT) != 0;
|
||||
}
|
||||
|
||||
void m68000_base_device::postload()
|
||||
void m68000_base_device::device_post_load()
|
||||
{
|
||||
m68ki_set_sr_noint_nosp(m_save_sr);
|
||||
//fprintf(stderr, "Reloaded, pc=%x\n", REG_PC(m68k));
|
||||
@ -1078,13 +1078,8 @@ void m68000_base_device::init_cpu_common(void)
|
||||
save_item(NAME(m_mmu_last_page_entry));
|
||||
save_item(NAME(m_mmu_last_page_entry_addr));
|
||||
|
||||
for (int i=0; i<MMU_ATC_ENTRIES;i++) {
|
||||
save_item(NAME(m_mmu_atc_tag[i]), i);
|
||||
save_item(NAME(m_mmu_atc_data[i]), i);
|
||||
}
|
||||
|
||||
machine().save().register_presave(save_prepost_delegate(FUNC(m68000_base_device::presave), this));
|
||||
machine().save().register_postload(save_prepost_delegate(FUNC(m68000_base_device::postload), this));
|
||||
save_item(NAME(m_mmu_atc_tag));
|
||||
save_item(NAME(m_mmu_atc_data));
|
||||
|
||||
set_icountptr(m_icount);
|
||||
m_icount = 0;
|
||||
|
@ -34,7 +34,6 @@ protected:
|
||||
// device-level overrides
|
||||
virtual void device_start() override;
|
||||
virtual void device_reset() override;
|
||||
virtual void device_post_load() override { }
|
||||
virtual void device_clock_changed() override { }
|
||||
virtual space_config_vector memory_space_config() const override;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user