Reapply "[x64] Zero extend on mov to 8bit register"
This reverts commit 3a6f63f34f.
(The issue wasn't xbyak but rather cherrypick order wrt to
other commits, xbyak upgrade was a red herring)
This commit is contained in:
@@ -2879,9 +2879,10 @@ struct SHL_V128 : Sequence<SHL_V128, I<OPCODE_SHL, V128Op, V128Op, I8Op>> {
|
|||||||
// Linux/Mac System V ABI: __m128i passed in xmm0, return in xmm0
|
// Linux/Mac System V ABI: __m128i passed in xmm0, return in xmm0
|
||||||
e.vmovaps(e.xmm0, src1);
|
e.vmovaps(e.xmm0, src1);
|
||||||
if (i.src2.is_constant) {
|
if (i.src2.is_constant) {
|
||||||
e.mov(e.GetNativeParam(1), i.src2.constant());
|
e.mov(e.GetNativeParam(0), i.src2.constant());
|
||||||
} else {
|
} else {
|
||||||
e.mov(e.GetNativeParam(1), i.src2);
|
// Zero-extend the 8-bit register to avoid garbage in upper bits
|
||||||
|
e.movzx(e.GetNativeParam(0).cvt32(), i.src2);
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
e.CallNativeSafe(reinterpret_cast<void*>(EmulateShlV128));
|
e.CallNativeSafe(reinterpret_cast<void*>(EmulateShlV128));
|
||||||
|
|||||||
Reference in New Issue
Block a user