summaryrefslogtreecommitdiff
path: root/opcodes/i386-opc.h
diff options
context:
space:
mode:
authorJan Beulich <jbeulich@suse.com>2022-09-30 10:12:45 +0200
committerJan Beulich <jbeulich@suse.com>2022-09-30 10:12:45 +0200
commit1cb0ab18ad24ddcedc57b40901153c36e97d6e2e (patch)
treebc0e0caa28c9d5229766fee3ee71fdc840d463cd /opcodes/i386-opc.h
parentc4a7e6b56218e1d5a858682186b542e2eae01a4a (diff)
downloadbinutils-gdb-1cb0ab18ad24ddcedc57b40901153c36e97d6e2e.tar.gz
x86/Intel: restrict suffix derivation
While in some cases deriving an AT&T-style suffix from an Intel syntax memory operand size specifier is necessary, in many cases this is not only pointless, but has led to the introduction of various workarounds: Excessive use of IgnoreSize and NoRex64 as well as the ToDword and ToQword attributes. Suppress suffix derivation when we can clearly tell that the memory operand's size isn't going to be needed to infer the possible need for the low byte/word opcode bit or an operand size prefix (0x66 or REX.W). As a result ToDword and ToQword can be dropped entirely, plus a fair number of IgnoreSize and NoRex64 can also be got rid of. Note that IgnoreSize needs to remain on legacy encoded SIMD insns with GPR operand, to avoid emitting an operand size prefix in 16-bit mode. (Since 16-bit code using SIMD insns isn't well tested, clone an existing testcase just enough to cover a few insns which are potentially problematic but are being touched here.) Note that while folding the VCVT{,T}S{S,D}2SI templates, VCVT{,T}SH2SI isn't included there. This is to fulfill the request of not allowing L and Q suffixes there, despite the inconsistency with VCVT{,T}S{S,D}2SI.
Diffstat (limited to 'opcodes/i386-opc.h')
-rw-r--r--opcodes/i386-opc.h6
1 files changed, 0 insertions, 6 deletions
diff --git a/opcodes/i386-opc.h b/opcodes/i386-opc.h
index 248e576d2f5..c033aeb8e07 100644
--- a/opcodes/i386-opc.h
+++ b/opcodes/i386-opc.h
@@ -521,10 +521,6 @@ enum
#define PrefixHLELock 5 /* Okay with a LOCK prefix. */
#define PrefixHLEAny 6 /* Okay with or without a LOCK prefix. */
PrefixOk,
- /* Convert to DWORD */
- ToDword,
- /* Convert to QWORD */
- ToQword,
/* Address prefix changes register operand */
AddrPrefixOpReg,
/* opcode is a prefix */
@@ -740,8 +736,6 @@ typedef struct i386_opcode_modifier
unsigned int regkludge:1;
unsigned int implicit1stxmm0:1;
unsigned int prefixok:3;
- unsigned int todword:1;
- unsigned int toqword:1;
unsigned int addrprefixopreg:1;
unsigned int isprefix:1;
unsigned int immext:1;