#510 MOVHPS rejects QWORD size parameter

open
nobody
Assembler (85)
5
2010-10-04
2010-10-04
No

movq QWORD [rsi], xmm0
movhps QWORD [rdi], xmm0
compiles both with:
yasm -f elf64
as -msyntax=intel -mnaked-reg
as
0: 66 0f d6 06 movq QWORD PTR [rsi],xmm0
4: 0f 17 07 movhps QWORD PTR [rdi],xmm0

but nasm complains:
1.asm:2: error: mismatch in operand sizes

removing QWORD works even with nasm but that should not be required:
movq QWORD [rsi], xmm0
movhps [rdi], xmm0

Discussion

  • H. Peter Anvin

    H. Peter Anvin - 2010-10-04

    We seem, in fact, to have this problem with all the Katmai instructions.

     
  • H. Peter Anvin

    H. Peter Anvin - 2010-10-04

    The problem being that the Katmai instructions are annotated neither with Sx flags nor with explicit memory sizes.

     
  • Cyrill Gorcunov

    Cyrill Gorcunov - 2010-10-04

    yup, noticed it too, for these particular instructions mem64 is preferred. I hope to handle them in a couple of days, though I'm free to be beaten on that ;)

     
  • Nobody/Anonymous

    There is a similar issue with some Willammette instructions, like MOVSD, f.i.

    movsd xmm0, [eax]

    is accepted, but

    movsd xmm0, qword [eax]

    isn't

     
  • Cyrill Gorcunov

    Cyrill Gorcunov - 2010-11-23

    ok, I've just covered katmai instructions I guess and pushed upstream, so it either will be in 2.09.05 or later after the patch has been more tested/reviewed

     

Log in to post a comment.