bool is_cycle_ce(uaecptr addr)
{
- addr &= currprefs.address_space_24 ? 0x00ffffff : 0xffffffff;
addrbank *ab = get_mem_bank_real(addr);
if (!ab || (ab->flags & ABFLAG_CHIPRAM) || ab == &custom_bank) {
int hpos = current_hpos();
{
membank_total = currprefs.address_space_24 ? 256 : 65536;
deinitialize_memwatch ();
- debug_mem_banks = xcalloc (addrbank*, membank_total);
+ debug_mem_banks = xcalloc (addrbank*, 65536);
+ if (!debug_mem_banks)
+ return;
+ if (membank_total < 65536) {
+ for (int i = 256; i < 65536; i++) {
+ debug_mem_banks[i] = &dummy_bank;
+ }
+ }
debug_mem_area = xcalloc (addrbank, membank_total);
membank_stores = xcalloc (struct membank_store, MEMWATCH_STORE_SLOTS);
for (int i = 0; i < MEMWATCH_TOTAL; i++) {