MMU: fix problems with blocks that cross vmem page boundaries
In rare cases, this can result in a violation of the JIT block cache constraint that blocks must end in the same place. This can cause instability, lockups, due to blocks not properly being invalidated properly. l Please enter the commit message for your changes. Lines starting
This commit is contained in:
parent
b058bbd223
commit
e85f0ff179
|
@ -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);
|
||||
|
|
Loading…
Reference in New Issue