From f3fb99446d89ca6e376002ec7c7af009d95ed075 Mon Sep 17 00:00:00 2001 From: "XTra.KrazzY" Date: Thu, 4 Dec 2008 19:12:09 +0000 Subject: [PATCH] stwcxd and lwarx are now emulated properly. Sonic Unleashed boots! git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@1398 8ced0084-cf51-0410-be5f-012b33b47a6e --- .../Src/PowerPC/Interpreter/Interpreter_LoadStore.cpp | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/Source/Core/Core/Src/PowerPC/Interpreter/Interpreter_LoadStore.cpp b/Source/Core/Core/Src/PowerPC/Interpreter/Interpreter_LoadStore.cpp index 6687b5a7b2..ffd87f6b08 100644 --- a/Source/Core/Core/Src/PowerPC/Interpreter/Interpreter_LoadStore.cpp +++ b/Source/Core/Core/Src/PowerPC/Interpreter/Interpreter_LoadStore.cpp @@ -597,7 +597,7 @@ void lwarx(UGeckoInstruction _inst) void stwcxd(UGeckoInstruction _inst) { - // This instruction, too + // This instruction, too //PanicAlert("stwcxd - suspicious instruction"); // Stores Word Conditional indeXed @@ -609,13 +609,12 @@ void stwcxd(UGeckoInstruction _inst) if(uAddress == g_reserveAddr) { Memory::Write_U32(m_GPR[_inst.RS], uAddress); g_bReserve = false; - + SetCRField(0, 2 | XER.SO); return; } - } - - // TODO: Set CR0 to IS_XER_SO + } + SetCRField(0, XER.SO); } void stwux(UGeckoInstruction _inst)