CPU/Recompiler: Reserve whole fastmem region to avoid clashes

This commit is contained in:
Connor McLaughlin
2021-04-11 12:42:51 +10:00
parent 8df0496dc1
commit 922d320523
13 changed files with 170 additions and 68 deletions

View File

@ -679,9 +679,6 @@ bool RecreateGPU(GPURenderer renderer, bool update_display /* = true*/)
return false;
}
// reinitialize the code cache because the address space could change
CPU::CodeCache::Reinitialize();
if (state_valid)
{
state_stream->SeekAbsolute(0);
@ -1940,10 +1937,6 @@ bool InsertMedia(const char* path)
UpdateMemoryCards();
}
// reinitialize recompiler, because especially with preloading this might overlap the fastmem area
if (g_settings.IsUsingCodeCache())
CPU::CodeCache::Reinitialize();
ClearMemorySaveStates();
return true;
}
@ -2069,10 +2062,6 @@ bool SwitchMediaSubImage(u32 index)
image->GetSubImageMetadata(index, "title").c_str(), index + 1u, image->GetMetadata("title").c_str());
g_cdrom.InsertMedia(std::move(image));
// reinitialize recompiler, because especially with preloading this might overlap the fastmem area
if (g_settings.IsUsingCodeCache())
CPU::CodeCache::Reinitialize();
ClearMemorySaveStates();
return true;
}