[Issue 16857] New: inline assembler reverses operands of VPEXTRW instruction

via Digitalmars-d-bugs digitalmars-d-bugs at puremagic.com
Tue Nov 29 22:08:55 PST 2016


https://issues.dlang.org/show_bug.cgi?id=16857

          Issue ID: 16857
           Summary: inline assembler reverses operands of VPEXTRW
                    instruction
           Product: D
           Version: D2
          Hardware: All
                OS: All
            Status: NEW
          Severity: major
          Priority: P1
         Component: dmd
          Assignee: nobody at puremagic.com
          Reporter: bugzilla at digitalmars.com

The following code:

  void foo() {
    asm {
        vpextrw EBX, XMM2, 0xF;
    }
  }

Compiles to:

        C5 F9 C5 DA 0F          vpextrw EDX,XMM3,0Fh

But the 'modregrm' DA should be D3, i.e. the 'reg' and 'rm' fields are swapped.
This reversal doesn't happen with the vpextrb instruction.

--


More information about the Digitalmars-d-bugs mailing list