summaryrefslogtreecommitdiff
path: root/Source/Core
diff options
context:
space:
mode:
authorPierre <pierre@pirsoft.de>2012-08-25 01:00:13 +0200
committerPierre <pierre@pirsoft.de>2013-04-14 13:34:29 +0200
commit6b5b8ab5bee7283281e53df40ebc881570dc74fa (patch)
tree5c4650860ad78cc3dedd84525b0da036e6758ee4 /Source/Core
parent701b5916ababc24ca62910d6874d9d31c037ee93 (diff)
Implement and use MOVZX(64, 32,...)
Probably better to keep that same-register-MOV assert useful. Also, explicit type extension documents whats happening. Internally, this boils down to the original MOV, but without the assert.
Diffstat (limited to 'Source/Core')
-rw-r--r--Source/Core/Common/Src/x64Emitter.cpp4
-rw-r--r--Source/Core/Core/Src/PowerPC/Jit64/Jit_Integer.cpp2
2 files changed, 5 insertions, 1 deletions
diff --git a/Source/Core/Common/Src/x64Emitter.cpp b/Source/Core/Common/Src/x64Emitter.cpp
index 022115a40a..e79f73fcca 100644
--- a/Source/Core/Common/Src/x64Emitter.cpp
+++ b/Source/Core/Common/Src/x64Emitter.cpp
@@ -768,6 +768,10 @@ void XEmitter::MOVZX(int dbits, int sbits, X64Reg dest, OpArg src)
Write8(0x0F);
Write8(0xB7);
}
+ else if (sbits == 32 && dbits == 64)
+ {
+ Write8(0x8B);
+ }
else
{
Crash();
diff --git a/Source/Core/Core/Src/PowerPC/Jit64/Jit_Integer.cpp b/Source/Core/Core/Src/PowerPC/Jit64/Jit_Integer.cpp
index 3d88d687e0..b444dbd783 100644
--- a/Source/Core/Core/Src/PowerPC/Jit64/Jit_Integer.cpp
+++ b/Source/Core/Core/Src/PowerPC/Jit64/Jit_Integer.cpp
@@ -1977,7 +1977,7 @@ void Jit64::slwx(UGeckoInstruction inst)
}
else
{
- MOV(32, gpr.R(a), gpr.R(a));
+ MOVZX(64, 32, gpr.R(a).GetSimpleReg(), gpr.R(a));
}
gpr.UnlockAll();
gpr.UnlockAllX();