[llvm-dev] Bug in X86 assembler?

Jun Koi via llvm-dev llvm-dev at lists.llvm.org
Wed Feb 17 08:10:58 PST 2016


I find that the X86 assembler can compile code like "mov r8, 0x12345678"
without any issues.

$ echo "mov r8, 0x12345678"|./bin/llvm-mc -assemble -show-encoding
-x86-asm-syntax=intel -print-imm-hex -triple=x86_64
    movq    $0x12345678, %r8        # encoding:

However, it fails to compile "mov r8, 0x1234567800":

$ echo "mov r8, 0x1234567800"|./bin/llvm-mc -assemble -show-encoding
-x86-asm-syntax=intel -print-imm-hex -triple=x86_64
<stdin>:1:1: error: invalid operand for instruction
mov r8, 0x1234567800

Is this a bug?

Thank you,
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20160218/b288e8f1/attachment.html>

More information about the llvm-dev mailing list