From b8d4834cb1d54d722494bc03107472803353a18b Mon Sep 17 00:00:00 2001 From: Ryan Houdek Date: Wed, 10 Sep 2014 21:33:17 -0500 Subject: [PATCH] Fix the return value of PPCAnalyst. In situations where conditional continue isn't supported + if a JIT doesn't implement a instruction that has the FL_ENDBLOCK flag. This would cause an infinite loop. In reality all the JITs should implement every FL_ENDBLOCK instruction regardless, but JITIL doesn't implement tw/twi which are FL_ENDBLOCK instructions. --- Source/Core/Core/PowerPC/PPCAnalyst.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Source/Core/Core/PowerPC/PPCAnalyst.cpp b/Source/Core/Core/PowerPC/PPCAnalyst.cpp index f790f7d44b..55adc3f172 100644 --- a/Source/Core/Core/PowerPC/PPCAnalyst.cpp +++ b/Source/Core/Core/PowerPC/PPCAnalyst.cpp @@ -676,12 +676,12 @@ u32 PPCAnalyzer::Analyze(u32 address, CodeBlock *block, CodeBuffer *buffer, u32 if (!follow) { + address += 4; if (!conditional_continue && opinfo->flags & FL_ENDBLOCK) //right now we stop early { found_exit = true; break; } - address += 4; } // XXX: We don't support inlining yet. #if 0