mirror of
https://github.com/WinampDesktop/winamp.git
synced 2025-06-12 06:05:46 -04:00
CPU/CachedInterpreter: Fix infinite loop when block compile fails
This commit is contained in:
@ -194,6 +194,7 @@ static void ExecuteImpl()
|
|||||||
if (!block)
|
if (!block)
|
||||||
{
|
{
|
||||||
InterpretUncachedBlock<pgxp_mode>();
|
InterpretUncachedBlock<pgxp_mode>();
|
||||||
|
next_block_key = GetNextBlockKey();
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1918,7 +1918,8 @@ template<PGXPMode pgxp_mode>
|
|||||||
void InterpretUncachedBlock()
|
void InterpretUncachedBlock()
|
||||||
{
|
{
|
||||||
g_state.regs.npc = g_state.regs.pc;
|
g_state.regs.npc = g_state.regs.pc;
|
||||||
FetchInstruction();
|
if (!FetchInstruction())
|
||||||
|
return;
|
||||||
|
|
||||||
// At this point, pc contains the last address executed (in the previous block). The instruction has not been fetched
|
// At this point, pc contains the last address executed (in the previous block). The instruction has not been fetched
|
||||||
// yet. pc shouldn't be updated until the fetch occurs, that way the exception occurs in the delay slot.
|
// yet. pc shouldn't be updated until the fetch occurs, that way the exception occurs in the delay slot.
|
||||||
|
Reference in New Issue
Block a user