diff options
Diffstat (limited to 'compiler/utils')
-rw-r--r-- | compiler/utils/x86/assembler_x86.cc | 2 | ||||
-rw-r--r-- | compiler/utils/x86_64/assembler_x86_64.cc | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/compiler/utils/x86/assembler_x86.cc b/compiler/utils/x86/assembler_x86.cc index a2cbd8b..4c7c4e9 100644 --- a/compiler/utils/x86/assembler_x86.cc +++ b/compiler/utils/x86/assembler_x86.cc @@ -248,7 +248,7 @@ void X86Assembler::movw(const Address& dst, const Immediate& imm) { EmitOperandSizeOverride(); EmitUint8(0xC7); EmitOperand(0, dst); - CHECK(imm.is_int16()); + CHECK(imm.is_uint16() || imm.is_int16()); EmitUint8(imm.value() & 0xFF); EmitUint8(imm.value() >> 8); } diff --git a/compiler/utils/x86_64/assembler_x86_64.cc b/compiler/utils/x86_64/assembler_x86_64.cc index ade7a13..17339ae 100644 --- a/compiler/utils/x86_64/assembler_x86_64.cc +++ b/compiler/utils/x86_64/assembler_x86_64.cc @@ -298,7 +298,7 @@ void X86_64Assembler::movw(const Address& dst, const Immediate& imm) { EmitOptionalRex32(dst); EmitUint8(0xC7); EmitOperand(Register::RAX, dst); - CHECK(imm.is_int16()); + CHECK(imm.is_uint16() || imm.is_int16()); EmitUint8(imm.value() & 0xFF); EmitUint8(imm.value() >> 8); } |