Skip to content
Permalink
Browse files
Merge pull request #6523 from lioncash/cast
Interpreter_LoadStore: Remove unnecessary casts
  • Loading branch information
leoetlino committed Mar 26, 2018
2 parents eb489c0 + a45631c commit 97e4d3d
Showing 1 changed file with 8 additions and 8 deletions.
@@ -39,15 +39,15 @@ u32 Interpreter::Helper_Get_EA_UX(const UGeckoInstruction inst)

void Interpreter::lbz(UGeckoInstruction inst)
{
u32 temp = (u32)PowerPC::Read_U8(Helper_Get_EA(inst));
u32 temp = PowerPC::Read_U8(Helper_Get_EA(inst));
if (!(PowerPC::ppcState.Exceptions & EXCEPTION_DSI))
rGPR[inst.RD] = temp;
}

void Interpreter::lbzu(UGeckoInstruction inst)
{
u32 uAddress = Helper_Get_EA_U(inst);
u32 temp = (u32)PowerPC::Read_U8(uAddress);
u32 temp = PowerPC::Read_U8(uAddress);
if (!(PowerPC::ppcState.Exceptions & EXCEPTION_DSI))
{
rGPR[inst.RD] = temp;
@@ -161,7 +161,7 @@ void Interpreter::lhau(UGeckoInstruction inst)

void Interpreter::lhz(UGeckoInstruction inst)
{
u32 temp = (u32)(u16)PowerPC::Read_U16(Helper_Get_EA(inst));
u32 temp = PowerPC::Read_U16(Helper_Get_EA(inst));
if (!(PowerPC::ppcState.Exceptions & EXCEPTION_DSI))
{
rGPR[inst.RD] = temp;
@@ -171,7 +171,7 @@ void Interpreter::lhz(UGeckoInstruction inst)
void Interpreter::lhzu(UGeckoInstruction inst)
{
u32 uAddress = Helper_Get_EA_U(inst);
u32 temp = (u32)(u16)PowerPC::Read_U16(uAddress);
u32 temp = PowerPC::Read_U16(uAddress);
if (!(PowerPC::ppcState.Exceptions & EXCEPTION_DSI))
{
rGPR[inst.RD] = temp;
@@ -426,7 +426,7 @@ void Interpreter::icbi(UGeckoInstruction inst)
void Interpreter::lbzux(UGeckoInstruction inst)
{
u32 uAddress = Helper_Get_EA_UX(inst);
u32 temp = (u32)PowerPC::Read_U8(uAddress);
u32 temp = PowerPC::Read_U8(uAddress);
if (!(PowerPC::ppcState.Exceptions & EXCEPTION_DSI))
{
rGPR[inst.RD] = temp;
@@ -436,7 +436,7 @@ void Interpreter::lbzux(UGeckoInstruction inst)

void Interpreter::lbzx(UGeckoInstruction inst)
{
u32 temp = (u32)PowerPC::Read_U8(Helper_Get_EA_X(inst));
u32 temp = PowerPC::Read_U8(Helper_Get_EA_X(inst));
if (!(PowerPC::ppcState.Exceptions & EXCEPTION_DSI))
{
rGPR[inst.RD] = temp;
@@ -465,7 +465,7 @@ void Interpreter::lhax(UGeckoInstruction inst)

void Interpreter::lhbrx(UGeckoInstruction inst)
{
u32 temp = (u32)Common::swap16(PowerPC::Read_U16(Helper_Get_EA_X(inst)));
u32 temp = Common::swap16(PowerPC::Read_U16(Helper_Get_EA_X(inst)));
if (!(PowerPC::ppcState.Exceptions & EXCEPTION_DSI))
{
rGPR[inst.RD] = temp;
@@ -475,7 +475,7 @@ void Interpreter::lhbrx(UGeckoInstruction inst)
void Interpreter::lhzux(UGeckoInstruction inst)
{
u32 uAddress = Helper_Get_EA_UX(inst);
u32 temp = (u32)PowerPC::Read_U16(uAddress);
u32 temp = PowerPC::Read_U16(uAddress);
if (!(PowerPC::ppcState.Exceptions & EXCEPTION_DSI))
{
rGPR[inst.RD] = temp;

0 comments on commit 97e4d3d

Please sign in to comment.