mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-09-24 12:22:34 -06:00
Merge pull request #1804 from FioraAeterna/fastermmu2_master
MMU: various improvements, bugfixes, optimizations
This commit is contained in:
@ -649,7 +649,7 @@ u32 PPCAnalyzer::Analyze(u32 address, CodeBlock *block, CodeBuffer *buffer, u32
|
||||
bool virtualAddr = SConfig::GetInstance().m_LocalCoreStartupParameter.bMMU && (address & JIT_ICACHE_VMEM_BIT);
|
||||
if (virtualAddr)
|
||||
{
|
||||
if (!Memory::TranslateAddress(address, Memory::FLAG_NO_EXCEPTION))
|
||||
if (!Memory::TranslateAddress<Memory::FLAG_NO_EXCEPTION>(address))
|
||||
{
|
||||
// Memory exception occurred during instruction fetch
|
||||
block->m_memory_exception = true;
|
||||
@ -670,6 +670,15 @@ u32 PPCAnalyzer::Analyze(u32 address, CodeBlock *block, CodeBuffer *buffer, u32
|
||||
|
||||
if (inst.hex != 0)
|
||||
{
|
||||
// Slight hack: the JIT block cache currently assumes all blocks end at the same place,
|
||||
// but broken blocks due to page faults break this assumption. Avoid this by just ending
|
||||
// all virtual memory instruction blocks at page boundaries.
|
||||
// FIXME: improve the JIT block cache so we don't need to do this.
|
||||
if (virtualAddr && i > 0 && (address & 0xfff) == 0)
|
||||
{
|
||||
break;
|
||||
}
|
||||
|
||||
num_inst++;
|
||||
memset(&code[i], 0, sizeof(CodeOp));
|
||||
GekkoOPInfo *opinfo = GetOpInfo(inst);
|
||||
|
Reference in New Issue
Block a user