]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commit
x86: utilize X macro in EVEX decoding
authorJan Beulich <jbeulich@suse.com>
Tue, 9 Jun 2020 06:57:22 +0000 (08:57 +0200)
committerJan Beulich <jbeulich@suse.com>
Tue, 9 Jun 2020 06:57:22 +0000 (08:57 +0200)
commit97e6786a6e354de573a1ec8c5021addf0066417a
treec0e7c7c5a2bfa29d2a702c233c3f7ead876ee6b3
parentbf926894b63fef2559685909ea2e9f794648a256
x86: utilize X macro in EVEX decoding

For major opcodes allowing only packed FP kinds of operands, i.e. the
ones where legacy and AVX decoding uses the X macro, we can do so for
AVX512 as well, by attaching to the checking logic the "EVEX.W must
match presence of embedded 66 prefix" rule. (Encodings not following
this general pattern simply may not gain the PREFIX_OPCODE attribute.)

Note that testing of the thus altered decoding has already been put in
place by "x86: correct decoding of packed-FP-only AVX encodings".

This can also be at least partly applied to scalar-FP-only insns (i.e.
V{,U}COMIS{S,D}) as well as the vector-FP forms of insns also allowing
scalar encodings (e.g. VADDP{S,D}).

Take the opportunity and also fix EVEX-encoded VMOVNTP{S,D} as well as
to-memory forms of VMOV{L,H}PS and both forms of VMOV{L,H}PD to wrongly
disassemble with only register operands.
opcodes/ChangeLog
opcodes/i386-dis-evex-mod.h
opcodes/i386-dis-evex-prefix.h
opcodes/i386-dis-evex-w.h
opcodes/i386-dis-evex.h
opcodes/i386-dis.c