From c24cedc03baf815a79cba9760b91dd0622a67057 Mon Sep 17 00:00:00 2001 From: Shawn Hoffman Date: Tue, 18 Jan 2011 05:59:38 +0000 Subject: [PATCH] fixes for jit64 twx git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6873 8ced0084-cf51-0410-be5f-012b33b47a6e --- Source/Core/Core/Src/PowerPC/Jit64/Jit_Integer.cpp | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/Source/Core/Core/Src/PowerPC/Jit64/Jit_Integer.cpp b/Source/Core/Core/Src/PowerPC/Jit64/Jit_Integer.cpp index be8a126228..01c6d0b8c9 100644 --- a/Source/Core/Core/Src/PowerPC/Jit64/Jit_Integer.cpp +++ b/Source/Core/Core/Src/PowerPC/Jit64/Jit_Integer.cpp @@ -1501,6 +1501,8 @@ void Jit64::twx(UGeckoInstruction inst) gpr.Flush(FLUSH_ALL); fpr.Flush(FLUSH_ALL); + MOV(8, R(AL), Imm8(inst.TO)); + if (inst.OPCD == 3) // twi CMP(32, gpr.R(a), gpr.R(inst.RB)); else // tw @@ -1514,23 +1516,23 @@ void Jit64::twx(UGeckoInstruction inst) FixupBranch lg = J_CC(CC_O); SetJumpTarget(al); - TEST(8, R(BL), Imm8(16)); + TEST(8, R(AL), Imm8(16)); FixupBranch exit1 = J_CC(CC_NZ); FixupBranch take1 = J(); SetJumpTarget(ag); - TEST(8, R(BL), Imm8(8)); + TEST(8, R(AL), Imm8(8)); FixupBranch exit2 = J_CC(CC_NZ); FixupBranch take2 = J(); SetJumpTarget(ae); - TEST(8, R(BL), Imm8(4)); + TEST(8, R(AL), Imm8(4)); FixupBranch exit3 = J_CC(CC_NZ); FixupBranch take3 = J(); SetJumpTarget(ll); - TEST(8, R(BL), Imm8(2)); + TEST(8, R(AL), Imm8(2)); FixupBranch exit4 = J_CC(CC_NZ); FixupBranch take4 = J(); SetJumpTarget(lg); - TEST(8, R(BL), Imm8(1)); + TEST(8, R(AL), Imm8(1)); FixupBranch exit5 = J_CC(CC_NZ); FixupBranch take5 = J(); @@ -1548,4 +1550,5 @@ void Jit64::twx(UGeckoInstruction inst) SetJumpTarget(exit3); SetJumpTarget(exit4); SetJumpTarget(exit5); + WriteExit(js.compilerPC + 4, 1); }