Bug 18738 - Wrong memory operand size for x86 GATHER/SCATTER instructions
Summary: Wrong memory operand size for x86 GATHER/SCATTER instructions
Status: NEW
Alias: None
Product: binutils
Classification: Unclassified
Component: binutils (show other bugs)
Version: 2.24
: P2 minor
Target Milestone: ---
Assignee: Alexander Fomin
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-07-29 20:22 UTC by Michael Rolle
Modified: 2015-09-01 10:00 UTC (History)
2 users (show)

See Also:
Host:
Target:
Build:
Last reconfirmed:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Michael Rolle 2015-07-29 20:22:55 UTC
objdump disassembles gather/scatter instructions showing the vector operand size as the memory operand size.  However, the Intel doc says it is the element size.

In these examples:

   0:   62 22 7d 41 93 74 b9    vgatherqps ymm30{k1},YMMWORD PTR [rcx+zmm31*4+0x100]
   7:   40
   8:   62 22 7d 41 a3 74 b9    vscatterqps YMMWORD PTR [rcx+zmm31*4+0x100]{k1},ymm30
   f:   40

YMMWORD PTR should be DWORD PTR.

(objdump did get the disp*N compression right, converting a 40h displacement byte into a 0x100 displacement.)

See also bug 18737 for similar problem with gas assembler.