Merge branch 'release0227' into mainline-master

This commit is contained in:
Vas Crabb 2020-12-29 04:45:24 +11:00
commit f6f0901551
4 changed files with 99 additions and 78 deletions

View File

@ -13,13 +13,14 @@
-- specify available CPU cores -- specify available CPU cores
-------------------------------------------------- --------------------------------------------------
CPUS["M6502"] = true CPUS["DSP16"] = true -- for qsound
CPUS["H6280"] = true CPUS["H6280"] = true
CPUS["KS0164"] = true
CPUS["M6502"] = true
CPUS["M680X0"] = true CPUS["M680X0"] = true
CPUS["MCS48"] = true CPUS["MCS48"] = true
CPUS["SH"] = true CPUS["SH"] = true
CPUS["Z80"] = true CPUS["Z80"] = true
CPUS["DSP16"] = true -- for qsound
-------------------------------------------------- --------------------------------------------------
-- specify available sound cores; some of these are -- specify available sound cores; some of these are
@ -37,6 +38,7 @@ SOUNDS["IREMGA20"] = true
SOUNDS["K051649"] = true SOUNDS["K051649"] = true
SOUNDS["K053260"] = true SOUNDS["K053260"] = true
SOUNDS["K054539"] = true SOUNDS["K054539"] = true
SOUNDS["KS0164"] = true
SOUNDS["MULTIPCM"] = true SOUNDS["MULTIPCM"] = true
SOUNDS["NES_APU"] = true SOUNDS["NES_APU"] = true
SOUNDS["OKIM6258"] = true SOUNDS["OKIM6258"] = true
@ -83,6 +85,7 @@ MACHINES["Z80DAISY"] = true
-------------------------------------------------- --------------------------------------------------
-- specify available bus cores -- specify available bus cores
-------------------------------------------------- --------------------------------------------------
BUSES["MIDI"] = true
-------------------------------------------------- --------------------------------------------------

View File

@ -371,6 +371,25 @@ void imagetek_i4100_device::device_start()
void imagetek_i4100_device::device_reset() void imagetek_i4100_device::device_reset()
{ {
m_rombank = 0;
m_crtc_unlock = false;
m_sprite_count = 0;
m_sprite_priority = 0;
m_sprite_xoffset = 0;
m_sprite_yoffset = 0;
m_sprite_color_code = 0;
for(int i=0; i != 3; i++) {
m_layer_priority[i] = 0;
m_layer_tile_select[i] = false;
}
m_background_color = 0;
m_screen_xoffset = 0;
m_screen_yoffset = 0;
m_screen_blank = false;
m_screen_flip = false;
expand_gfx1(); expand_gfx1();
} }

View File

@ -1859,8 +1859,6 @@ private:
address_space * m_space; address_space * m_space;
handler_entry * m_handler_read; handler_entry * m_handler_read;
handler_entry * m_handler_write; handler_entry * m_handler_write;
std::function<void (int)> m_select_a;
std::function<void (int)> m_select_u;
int m_cur_id; int m_cur_id;
int m_cur_slot; int m_cur_slot;
std::string m_context; std::string m_context;

View File

@ -587,7 +587,8 @@ template<int Level, int Width, int AddrShift, endianness_t Endian> void memory_v
} }
// Force the slot to exist, in case the map is empty // Force the slot to exist, in case the map is empty
m_view.m_select_u(m_id); r()->select_u(m_id);
w()->select_u(m_id);
// install the handlers, using the original, unadjusted memory map // install the handlers, using the original, unadjusted memory map
for(const address_map_entry &entry : map->m_entrylist) { for(const address_map_entry &entry : map->m_entrylist) {
@ -615,14 +616,15 @@ void memory_view::register_state()
{ {
m_device.machine().save().save_item(&m_device, "view", m_name.c_str(), 0, NAME(m_cur_slot)); m_device.machine().save().save_item(&m_device, "view", m_name.c_str(), 0, NAME(m_cur_slot));
m_device.machine().save().save_item(&m_device, "view", m_name.c_str(), 0, NAME(m_cur_id)); m_device.machine().save().save_item(&m_device, "view", m_name.c_str(), 0, NAME(m_cur_id));
m_device.machine().save().register_postload(save_prepost_delegate(NAME([this]() { m_select_a(m_cur_id); }))); m_device.machine().save().register_postload(save_prepost_delegate(NAME([this]() { m_handler_read->select_a(m_cur_id); m_handler_write->select_a(m_cur_id); })));
} }
void memory_view::disable() void memory_view::disable()
{ {
m_cur_slot = -1; m_cur_slot = -1;
m_cur_id = -1; m_cur_id = -1;
m_select_a(-1); m_handler_read->select_a(-1);
m_handler_write->select_a(-1);
} }
void memory_view::select(int slot) void memory_view::select(int slot)
@ -633,7 +635,8 @@ void memory_view::select(int slot)
m_cur_slot = slot; m_cur_slot = slot;
m_cur_id = i->second; m_cur_id = i->second;
m_select_a(m_cur_id); m_handler_read->select_a(m_cur_id);
m_handler_write->select_a(m_cur_id);
} }
int memory_view::id_to_slot(int id) const int memory_view::id_to_slot(int id) const
@ -655,78 +658,68 @@ void memory_view::initialize_from_address_map(offs_t addrstart, offs_t addrend,
} }
namespace { namespace {
template<int HighBits, int Width, int AddrShift, endianness_t Endian> void h_make_1(address_space &space, memory_view &view, handler_entry *&r, handler_entry *&w, std::function<void (int)> &sa, std::function<void (int)> &su) { template<int Width, int AddrShift, endianness_t Endian> void h_make_1(int HighBits, address_space &space, memory_view &view, handler_entry *&r, handler_entry *&w) {
auto rx = new handler_entry_read_dispatch <HighBits, Width, AddrShift, Endian>(&space, view);
auto wx = new handler_entry_write_dispatch<HighBits, Width, AddrShift, Endian>(&space, view);
r = rx;
w = wx;
sa = [rx, wx](int s) { rx->select_a(s); wx->select_a(s); };
su = [rx, wx](int s) { rx->select_u(s); wx->select_u(s); };
}
template<int Width, int AddrShift, endianness_t Endian> void h_make_2(int HighBits, address_space &space, memory_view &view, handler_entry *&r, handler_entry *&w, std::function<void (int)> &sa, std::function<void (int)> &su) {
switch(HighBits) { switch(HighBits) {
case 0: h_make_1<std::max(0, Width), Width, AddrShift, Endian>(space, view, r, w, sa, su); break; case 0: r = new handler_entry_read_dispatch<std::max(0, Width), Width, AddrShift, Endian>(&space, view); w = new handler_entry_write_dispatch<std::max(0, Width), Width, AddrShift, Endian>(&space, view); break;
case 1: h_make_1<std::max(1, Width), Width, AddrShift, Endian>(space, view, r, w, sa, su); break; case 1: r = new handler_entry_read_dispatch<std::max(1, Width), Width, AddrShift, Endian>(&space, view); w = new handler_entry_write_dispatch<std::max(1, Width), Width, AddrShift, Endian>(&space, view); break;
case 2: h_make_1<std::max(2, Width), Width, AddrShift, Endian>(space, view, r, w, sa, su); break; case 2: r = new handler_entry_read_dispatch<std::max(2, Width), Width, AddrShift, Endian>(&space, view); w = new handler_entry_write_dispatch<std::max(2, Width), Width, AddrShift, Endian>(&space, view); break;
case 3: h_make_1<std::max(3, Width), Width, AddrShift, Endian>(space, view, r, w, sa, su); break; case 3: r = new handler_entry_read_dispatch<std::max(3, Width), Width, AddrShift, Endian>(&space, view); w = new handler_entry_write_dispatch<std::max(3, Width), Width, AddrShift, Endian>(&space, view); break;
case 4: h_make_1< 4, Width, AddrShift, Endian>(space, view, r, w, sa, su); break; case 4: r = new handler_entry_read_dispatch< 4, Width, AddrShift, Endian>(&space, view); w = new handler_entry_write_dispatch< 4, Width, AddrShift, Endian>(&space, view); break;
case 5: h_make_1< 5, Width, AddrShift, Endian>(space, view, r, w, sa, su); break; case 5: r = new handler_entry_read_dispatch< 5, Width, AddrShift, Endian>(&space, view); w = new handler_entry_write_dispatch< 5, Width, AddrShift, Endian>(&space, view); break;
case 6: h_make_1< 6, Width, AddrShift, Endian>(space, view, r, w, sa, su); break; case 6: r = new handler_entry_read_dispatch< 6, Width, AddrShift, Endian>(&space, view); w = new handler_entry_write_dispatch< 6, Width, AddrShift, Endian>(&space, view); break;
case 7: h_make_1< 7, Width, AddrShift, Endian>(space, view, r, w, sa, su); break; case 7: r = new handler_entry_read_dispatch< 7, Width, AddrShift, Endian>(&space, view); w = new handler_entry_write_dispatch< 7, Width, AddrShift, Endian>(&space, view); break;
case 8: h_make_1< 8, Width, AddrShift, Endian>(space, view, r, w, sa, su); break; case 8: r = new handler_entry_read_dispatch< 8, Width, AddrShift, Endian>(&space, view); w = new handler_entry_write_dispatch< 8, Width, AddrShift, Endian>(&space, view); break;
case 9: h_make_1< 9, Width, AddrShift, Endian>(space, view, r, w, sa, su); break; case 9: r = new handler_entry_read_dispatch< 9, Width, AddrShift, Endian>(&space, view); w = new handler_entry_write_dispatch< 9, Width, AddrShift, Endian>(&space, view); break;
case 10: h_make_1<10, Width, AddrShift, Endian>(space, view, r, w, sa, su); break; case 10: r = new handler_entry_read_dispatch<10, Width, AddrShift, Endian>(&space, view); w = new handler_entry_write_dispatch<10, Width, AddrShift, Endian>(&space, view); break;
case 11: h_make_1<11, Width, AddrShift, Endian>(space, view, r, w, sa, su); break; case 11: r = new handler_entry_read_dispatch<11, Width, AddrShift, Endian>(&space, view); w = new handler_entry_write_dispatch<11, Width, AddrShift, Endian>(&space, view); break;
case 12: h_make_1<12, Width, AddrShift, Endian>(space, view, r, w, sa, su); break; case 12: r = new handler_entry_read_dispatch<12, Width, AddrShift, Endian>(&space, view); w = new handler_entry_write_dispatch<12, Width, AddrShift, Endian>(&space, view); break;
case 13: h_make_1<13, Width, AddrShift, Endian>(space, view, r, w, sa, su); break; case 13: r = new handler_entry_read_dispatch<13, Width, AddrShift, Endian>(&space, view); w = new handler_entry_write_dispatch<13, Width, AddrShift, Endian>(&space, view); break;
case 14: h_make_1<14, Width, AddrShift, Endian>(space, view, r, w, sa, su); break; case 14: r = new handler_entry_read_dispatch<14, Width, AddrShift, Endian>(&space, view); w = new handler_entry_write_dispatch<14, Width, AddrShift, Endian>(&space, view); break;
case 15: h_make_1<15, Width, AddrShift, Endian>(space, view, r, w, sa, su); break; case 15: r = new handler_entry_read_dispatch<15, Width, AddrShift, Endian>(&space, view); w = new handler_entry_write_dispatch<15, Width, AddrShift, Endian>(&space, view); break;
case 16: h_make_1<16, Width, AddrShift, Endian>(space, view, r, w, sa, su); break; case 16: r = new handler_entry_read_dispatch<16, Width, AddrShift, Endian>(&space, view); w = new handler_entry_write_dispatch<16, Width, AddrShift, Endian>(&space, view); break;
case 17: h_make_1<17, Width, AddrShift, Endian>(space, view, r, w, sa, su); break; case 17: r = new handler_entry_read_dispatch<17, Width, AddrShift, Endian>(&space, view); w = new handler_entry_write_dispatch<17, Width, AddrShift, Endian>(&space, view); break;
case 18: h_make_1<18, Width, AddrShift, Endian>(space, view, r, w, sa, su); break; case 18: r = new handler_entry_read_dispatch<18, Width, AddrShift, Endian>(&space, view); w = new handler_entry_write_dispatch<18, Width, AddrShift, Endian>(&space, view); break;
case 19: h_make_1<19, Width, AddrShift, Endian>(space, view, r, w, sa, su); break; case 19: r = new handler_entry_read_dispatch<19, Width, AddrShift, Endian>(&space, view); w = new handler_entry_write_dispatch<19, Width, AddrShift, Endian>(&space, view); break;
case 20: h_make_1<20, Width, AddrShift, Endian>(space, view, r, w, sa, su); break; case 20: r = new handler_entry_read_dispatch<20, Width, AddrShift, Endian>(&space, view); w = new handler_entry_write_dispatch<20, Width, AddrShift, Endian>(&space, view); break;
case 21: h_make_1<21, Width, AddrShift, Endian>(space, view, r, w, sa, su); break; case 21: r = new handler_entry_read_dispatch<21, Width, AddrShift, Endian>(&space, view); w = new handler_entry_write_dispatch<21, Width, AddrShift, Endian>(&space, view); break;
case 22: h_make_1<22, Width, AddrShift, Endian>(space, view, r, w, sa, su); break; case 22: r = new handler_entry_read_dispatch<22, Width, AddrShift, Endian>(&space, view); w = new handler_entry_write_dispatch<22, Width, AddrShift, Endian>(&space, view); break;
case 23: h_make_1<23, Width, AddrShift, Endian>(space, view, r, w, sa, su); break; case 23: r = new handler_entry_read_dispatch<23, Width, AddrShift, Endian>(&space, view); w = new handler_entry_write_dispatch<23, Width, AddrShift, Endian>(&space, view); break;
case 24: h_make_1<24, Width, AddrShift, Endian>(space, view, r, w, sa, su); break; case 24: r = new handler_entry_read_dispatch<24, Width, AddrShift, Endian>(&space, view); w = new handler_entry_write_dispatch<24, Width, AddrShift, Endian>(&space, view); break;
case 25: h_make_1<25, Width, AddrShift, Endian>(space, view, r, w, sa, su); break; case 25: r = new handler_entry_read_dispatch<25, Width, AddrShift, Endian>(&space, view); w = new handler_entry_write_dispatch<25, Width, AddrShift, Endian>(&space, view); break;
case 26: h_make_1<26, Width, AddrShift, Endian>(space, view, r, w, sa, su); break; case 26: r = new handler_entry_read_dispatch<26, Width, AddrShift, Endian>(&space, view); w = new handler_entry_write_dispatch<26, Width, AddrShift, Endian>(&space, view); break;
case 27: h_make_1<27, Width, AddrShift, Endian>(space, view, r, w, sa, su); break; case 27: r = new handler_entry_read_dispatch<27, Width, AddrShift, Endian>(&space, view); w = new handler_entry_write_dispatch<27, Width, AddrShift, Endian>(&space, view); break;
case 28: h_make_1<28, Width, AddrShift, Endian>(space, view, r, w, sa, su); break; case 28: r = new handler_entry_read_dispatch<28, Width, AddrShift, Endian>(&space, view); w = new handler_entry_write_dispatch<28, Width, AddrShift, Endian>(&space, view); break;
case 29: h_make_1<29, Width, AddrShift, Endian>(space, view, r, w, sa, su); break; case 29: r = new handler_entry_read_dispatch<29, Width, AddrShift, Endian>(&space, view); w = new handler_entry_write_dispatch<29, Width, AddrShift, Endian>(&space, view); break;
case 30: h_make_1<20, Width, AddrShift, Endian>(space, view, r, w, sa, su); break; case 30: r = new handler_entry_read_dispatch<30, Width, AddrShift, Endian>(&space, view); w = new handler_entry_write_dispatch<30, Width, AddrShift, Endian>(&space, view); break;
case 31: h_make_1<31, Width, AddrShift, Endian>(space, view, r, w, sa, su); break; case 31: r = new handler_entry_read_dispatch<31, Width, AddrShift, Endian>(&space, view); w = new handler_entry_write_dispatch<31, Width, AddrShift, Endian>(&space, view); break;
case 32: h_make_1<32, Width, AddrShift, Endian>(space, view, r, w, sa, su); break; case 32: r = new handler_entry_read_dispatch<32, Width, AddrShift, Endian>(&space, view); w = new handler_entry_write_dispatch<32, Width, AddrShift, Endian>(&space, view); break;
default: abort(); default: abort();
} }
} }
template<int Width, int AddrShift> void h_make_3(int HighBits, endianness_t Endian, address_space &space, memory_view &view, handler_entry *&r, handler_entry *&w, std::function<void (int)> &sa, std::function<void (int)> &su) { template<int Width, int AddrShift> void h_make_2(int HighBits, endianness_t Endian, address_space &space, memory_view &view, handler_entry *&r, handler_entry *&w) {
switch(Endian) { switch(Endian) {
case ENDIANNESS_LITTLE: h_make_2<Width, AddrShift, ENDIANNESS_LITTLE>(HighBits, space, view, r, w, sa, su); break; case ENDIANNESS_LITTLE: h_make_1<Width, AddrShift, ENDIANNESS_LITTLE>(HighBits, space, view, r, w); break;
case ENDIANNESS_BIG: h_make_2<Width, AddrShift, ENDIANNESS_BIG> (HighBits, space, view, r, w, sa, su); break; case ENDIANNESS_BIG: h_make_1<Width, AddrShift, ENDIANNESS_BIG> (HighBits, space, view, r, w); break;
default: abort(); default: abort();
} }
} }
void h_make(int HighBits, int Width, int AddrShift, endianness_t Endian, address_space &space, memory_view &view, handler_entry *&r, handler_entry *&w, std::function<void (int)> &sa, std::function<void (int)> &su) { void h_make(int HighBits, int Width, int AddrShift, endianness_t Endian, address_space &space, memory_view &view, handler_entry *&r, handler_entry *&w) {
switch (Width | (AddrShift + 4)) { switch (Width | (AddrShift + 4)) {
case 8|(4+1): h_make_3<0, 1>(HighBits, Endian, space, view, r, w, sa, su); break; case 8|(4+1): h_make_2<0, 1>(HighBits, Endian, space, view, r, w); break;
case 8|(4-0): h_make_3<0, 0>(HighBits, Endian, space, view, r, w, sa, su); break; case 8|(4-0): h_make_2<0, 0>(HighBits, Endian, space, view, r, w); break;
case 16|(4+3): h_make_3<1, 3>(HighBits, Endian, space, view, r, w, sa, su); break; case 16|(4+3): h_make_2<1, 3>(HighBits, Endian, space, view, r, w); break;
case 16|(4-0): h_make_3<1, 0>(HighBits, Endian, space, view, r, w, sa, su); break; case 16|(4-0): h_make_2<1, 0>(HighBits, Endian, space, view, r, w); break;
case 16|(4-1): h_make_3<1, -1>(HighBits, Endian, space, view, r, w, sa, su); break; case 16|(4-1): h_make_2<1, -1>(HighBits, Endian, space, view, r, w); break;
case 32|(4+3): h_make_3<2, 3>(HighBits, Endian, space, view, r, w, sa, su); break; case 32|(4+3): h_make_2<2, 3>(HighBits, Endian, space, view, r, w); break;
case 32|(4-0): h_make_3<2, 0>(HighBits, Endian, space, view, r, w, sa, su); break; case 32|(4-0): h_make_2<2, 0>(HighBits, Endian, space, view, r, w); break;
case 32|(4-1): h_make_3<2, -1>(HighBits, Endian, space, view, r, w, sa, su); break; case 32|(4-1): h_make_2<2, -1>(HighBits, Endian, space, view, r, w); break;
case 32|(4-2): h_make_3<2, -2>(HighBits, Endian, space, view, r, w, sa, su); break; case 32|(4-2): h_make_2<2, -2>(HighBits, Endian, space, view, r, w); break;
case 64|(4-0): h_make_3<3, 0>(HighBits, Endian, space, view, r, w, sa, su); break; case 64|(4-0): h_make_2<3, 0>(HighBits, Endian, space, view, r, w); break;
case 64|(4-1): h_make_3<3, -1>(HighBits, Endian, space, view, r, w, sa, su); break; case 64|(4-1): h_make_2<3, -1>(HighBits, Endian, space, view, r, w); break;
case 64|(4-2): h_make_3<3, -2>(HighBits, Endian, space, view, r, w, sa, su); break; case 64|(4-2): h_make_2<3, -2>(HighBits, Endian, space, view, r, w); break;
case 64|(4-3): h_make_3<3, -3>(HighBits, Endian, space, view, r, w, sa, su); break; case 64|(4-3): h_make_2<3, -3>(HighBits, Endian, space, view, r, w); break;
default: abort(); default: abort();
} }
} }
@ -757,7 +750,7 @@ std::pair<handler_entry *, handler_entry *> memory_view::make_handlers(address_s
break; break;
} }
h_make(awidth, m_config->data_width(), m_config->addr_shift(), m_config->endianness(), space, *this, m_handler_read, m_handler_write, m_select_a, m_select_u); h_make(awidth, m_config->data_width(), m_config->addr_shift(), m_config->endianness(), space, *this, m_handler_read, m_handler_write);
} }
return std::make_pair(m_handler_read, m_handler_write); return std::make_pair(m_handler_read, m_handler_write);
@ -802,7 +795,8 @@ template<int Level, int Width, int AddrShift, endianness_t Endian> void memory_v
offs_t nstart, nend, nmask, nmirror; offs_t nstart, nend, nmask, nmirror;
check_range_optimize_mirror("install_ram_generic", addrstart, addrend, addrmirror, nstart, nend, nmask, nmirror); check_range_optimize_mirror("install_ram_generic", addrstart, addrend, addrmirror, nstart, nend, nmask, nmirror);
m_view.m_select_u(m_id); r()->select_u(m_id);
w()->select_u(m_id);
// map for read // map for read
if (readorwrite == read_or_write::READ || readorwrite == read_or_write::READWRITE) if (readorwrite == read_or_write::READ || readorwrite == read_or_write::READWRITE)
@ -834,7 +828,8 @@ template<int Level, int Width, int AddrShift, endianness_t Endian> void memory_v
offs_t nstart, nend, nmask, nmirror; offs_t nstart, nend, nmask, nmirror;
check_range_optimize_mirror("unmap_generic", addrstart, addrend, addrmirror, nstart, nend, nmask, nmirror); check_range_optimize_mirror("unmap_generic", addrstart, addrend, addrmirror, nstart, nend, nmask, nmirror);
m_view.m_select_u(m_id); r()->select_u(m_id);
w()->select_u(m_id);
// read space // read space
if (readorwrite == read_or_write::READ || readorwrite == read_or_write::READWRITE) { if (readorwrite == read_or_write::READ || readorwrite == read_or_write::READWRITE) {
@ -858,7 +853,8 @@ template<int Level, int Width, int AddrShift, endianness_t Endian> void memory_v
offs_t nstart, nend, nmask, nmirror; offs_t nstart, nend, nmask, nmirror;
check_range_optimize_mirror("install_view", addrstart, addrend, addrmirror, nstart, nend, nmask, nmirror); check_range_optimize_mirror("install_view", addrstart, addrend, addrmirror, nstart, nend, nmask, nmirror);
m_view.m_select_u(m_id); r()->select_u(m_id);
w()->select_u(m_id);
auto handlers = view.make_handlers(*m_view.m_space, addrstart, addrend); auto handlers = view.make_handlers(*m_view.m_space, addrstart, addrend);
r()->populate(nstart, nend, nmirror, static_cast<handler_entry_read <Width, AddrShift, Endian> *>(handlers.first)); r()->populate(nstart, nend, nmirror, static_cast<handler_entry_read <Width, AddrShift, Endian> *>(handlers.first));
@ -873,7 +869,8 @@ template<int Level, int Width, int AddrShift, endianness_t Endian> memory_passth
if (!mph) if (!mph)
mph = m_view.m_space->make_mph(); mph = m_view.m_space->make_mph();
m_view.m_select_u(m_id); r()->select_u(m_id);
w()->select_u(m_id);
auto handler = new handler_entry_read_tap<Width, AddrShift, Endian>(m_view.m_space, *mph, name, tap); auto handler = new handler_entry_read_tap<Width, AddrShift, Endian>(m_view.m_space, *mph, name, tap);
r()->populate_passthrough(nstart, nend, nmirror, handler); r()->populate_passthrough(nstart, nend, nmirror, handler);
@ -891,7 +888,8 @@ template<int Level, int Width, int AddrShift, endianness_t Endian> memory_passth
if (!mph) if (!mph)
mph = m_view.m_space->make_mph(); mph = m_view.m_space->make_mph();
m_view.m_select_u(m_id); r()->select_u(m_id);
w()->select_u(m_id);
auto handler = new handler_entry_write_tap<Width, AddrShift, Endian>(m_view.m_space, *mph, name, tap); auto handler = new handler_entry_write_tap<Width, AddrShift, Endian>(m_view.m_space, *mph, name, tap);
w()->populate_passthrough(nstart, nend, nmirror, handler); w()->populate_passthrough(nstart, nend, nmirror, handler);
@ -909,7 +907,8 @@ template<int Level, int Width, int AddrShift, endianness_t Endian> memory_passth
if (!mph) if (!mph)
mph = m_view.m_space->make_mph(); mph = m_view.m_space->make_mph();
m_view.m_select_u(m_id); r()->select_u(m_id);
w()->select_u(m_id);
auto rhandler = new handler_entry_read_tap <Width, AddrShift, Endian>(m_view.m_space, *mph, name, tapr); auto rhandler = new handler_entry_read_tap <Width, AddrShift, Endian>(m_view.m_space, *mph, name, tapr);
r() ->populate_passthrough(nstart, nend, nmirror, rhandler); r() ->populate_passthrough(nstart, nend, nmirror, rhandler);
@ -942,7 +941,8 @@ template<int Level, int Width, int AddrShift, endianness_t Endian> void memory_v
offs_t nstart, nend, nmask, nmirror; offs_t nstart, nend, nmask, nmirror;
check_range_optimize_mirror("install_readwrite_port", addrstart, addrend, addrmirror, nstart, nend, nmask, nmirror); check_range_optimize_mirror("install_readwrite_port", addrstart, addrend, addrmirror, nstart, nend, nmask, nmirror);
m_view.m_select_u(m_id); r()->select_u(m_id);
w()->select_u(m_id);
// read handler // read handler
if (rtag != "") if (rtag != "")
@ -981,7 +981,8 @@ template<int Level, int Width, int AddrShift, endianness_t Endian> void memory_v
offs_t nstart, nend, nmask, nmirror; offs_t nstart, nend, nmask, nmirror;
check_range_optimize_mirror("install_bank_generic", addrstart, addrend, addrmirror, nstart, nend, nmask, nmirror); check_range_optimize_mirror("install_bank_generic", addrstart, addrend, addrmirror, nstart, nend, nmask, nmirror);
m_view.m_select_u(m_id); r()->select_u(m_id);
w()->select_u(m_id);
// map the read bank // map the read bank
if (rbank != nullptr) if (rbank != nullptr)