binutils-gdb/gas/doc
H.J. Lu bc31405ebb x86-64: Properly encode and decode movsxd
movsxd is a 64-bit only instruction.  It supports both 16-bit and 32-bit
destination registers.  Its AT&T mnemonic is movslq which only supports
64-bit destination register.  There is also a discrepancy between AMD64
and Intel64 on movsxd with 16-bit destination register.  AMD64 supports
32-bit source operand and Intel64 supports 16-bit source operand.

This patch updates movsxd encoding and decoding to alow 16-bit and 32-bit
destination registers.  It also handles movsxd with 16-bit destination
register for AMD64 and Intel 64.

gas/

	PR binutils/25445
	* config/tc-i386.c (check_long_reg): Also convert to QWORD for
	movsxd.
	* doc/c-i386.texi: Add a node for AMD64 vs. Intel64 ISA
	differences.  Document movslq and movsxd.
	* testsuite/gas/i386/i386.exp: Run PR binutils/25445 tests.
	* testsuite/gas/i386/x86-64-movsxd-intel.d: New file.
	* testsuite/gas/i386/x86-64-movsxd-intel64-intel.d: Likewise.
	* testsuite/gas/i386/x86-64-movsxd-intel64-inval.l: Likewise.
	* testsuite/gas/i386/x86-64-movsxd-intel64-inval.s: Likewise.
	* testsuite/gas/i386/x86-64-movsxd-intel64.d: Likewise.
	* testsuite/gas/i386/x86-64-movsxd-intel64.s: Likewise.
	* testsuite/gas/i386/x86-64-movsxd-inval.l: Likewise.
	* testsuite/gas/i386/x86-64-movsxd-inval.s: Likewise.
	* testsuite/gas/i386/x86-64-movsxd.d: Likewise.
	* testsuite/gas/i386/x86-64-movsxd.s: Likewise.

opcodes/

	PR binutils/25445
	* i386-dis.c (MOVSXD_Fixup): New function.
	(movsxd_mode): New enum.
	(x86_64_table): Use MOVSXD_Fixup and movsxd_mode on movsxd.
	(intel_operand_size): Handle movsxd_mode.
	(OP_E_register): Likewise.
	(OP_G): Likewise.
	* i386-opc.tbl: Remove Rex64 and allow 32-bit destination
	register on movsxd.  Add movsxd with 16-bit destination register
	for AMD64 and Intel64 ISAs.
	* i386-tbl.h: Regenerated.
2020-01-27 04:38:29 -08:00
..
all.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
as.texi Fix various assembler testsuite failures for the Z80 target. 2020-01-14 13:13:57 +00:00
c-aarch64.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-alpha.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-arc.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-arm.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-avr.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-bfin.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-bpf.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-cr16.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-cris.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-csky.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-d10v.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-d30v.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-epiphany.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-h8300.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-hppa.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-i386.texi x86-64: Properly encode and decode movsxd 2020-01-27 04:38:29 -08:00
c-ia64.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-ip2k.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-lm32.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-m32c.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-m32r.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-m68hc11.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-m68k.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-metag.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-microblaze.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-mips.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-mmix.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-msp430.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-mt.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-nds32.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-nios2.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-ns32k.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-or1k.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-pdp11.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-pj.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-ppc.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-pru.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-riscv.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-rl78.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-rx.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-s12z.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-s390.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-score.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-sh.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-sparc.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-tic6x.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-tic54x.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-tilegx.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-tilepro.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-v850.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-vax.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-visium.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-wasm32.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-xc16x.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-xgate.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-xstormy16.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-xtensa.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-z8k.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
c-z80.texi Fix various assembler testsuite failures for the Z80 target. 2020-01-14 13:13:57 +00:00
fdl.texi
h8.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
internals.texi Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
Makefile.am Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30
Makefile.in Update year range in copyright notice of binutils files 2020-01-01 18:42:54 +10:30