aboutsummaryrefslogtreecommitdiff
path: root/opcodes
diff options
context:
space:
mode:
authorJan Beulich <jbeulich@suse.com>2020-07-06 13:40:40 +0200
committerJan Beulich <jbeulich@suse.com>2020-07-06 13:40:40 +0200
commit6431c8015b1d8a75facbd2d0ec6a4f1e98167f72 (patch)
treebf95c450de65481de629c3c3afbd4c22944ae8ec /opcodes
parent6df22cf64c935c7a467759048858bb7e8ef70235 (diff)
downloadgdb-6431c8015b1d8a75facbd2d0ec6a4f1e98167f72.zip
gdb-6431c8015b1d8a75facbd2d0ec6a4f1e98167f72.tar.gz
gdb-6431c8015b1d8a75facbd2d0ec6a4f1e98167f72.tar.bz2
x86: honor VEX.W for VCVT{PH2PS,PS2PH}
Unlike for the EVEX-encoded versions, the VEX ones failed to decode VEX.W. Once the necessary adjustments are done, it becomes obvious that the EVEX and VEX table entries for VCVTPS2PH are identical and can hence be folded.
Diffstat (limited to 'opcodes')
-rw-r--r--opcodes/ChangeLog14
-rw-r--r--opcodes/i386-dis-evex-prefix.h6
-rw-r--r--opcodes/i386-dis-evex-w.h4
-rw-r--r--opcodes/i386-dis-evex.h2
-rw-r--r--opcodes/i386-dis.c16
5 files changed, 27 insertions, 15 deletions
diff --git a/opcodes/ChangeLog b/opcodes/ChangeLog
index f5463b0..296ef26 100644
--- a/opcodes/ChangeLog
+++ b/opcodes/ChangeLog
@@ -1,5 +1,19 @@
2020-07-06 Jan Beulich <jbeulich@suse.com>
+ * i386-dis.c (PREFIX_EVEX_0F3A1D, EVEX_W_0F3A1D_P_2): Delete.
+ (VEX_W_0F3813_P_2, VEX_W_0F3A1D_P_2): New enumerators.
+ (prefix_table): Reference VEX_W_0F3813_P_2 and VEX_W_0F3A1D_P_2
+ respectively.
+ (vex_w_table): New VEX_W_0F3813_P_2 and VEX_W_0F3A1D_P_2 table
+ entries.
+ * i386-dis-evex.h (evex_table): Reference VEX table entry for
+ opcode 0F3A1D.
+ * i386-dis-evex-prefix.h (PREFIX_EVEX_0F3A1D): Delete table
+ entry.
+ * i386-dis-evex-w.h (EVEX_W_0F3A1D_P_2): Likewise.
+
+2020-07-06 Jan Beulich <jbeulich@suse.com>
+
* i386-dis.c (PREFIX_EVEX_0F60, PREFIX_EVEX_0F61,
PREFIX_EVEX_0F63, PREFIX_EVEX_0F67, PREFIX_EVEX_0F68,
PREFIX_EVEX_0F69, PREFIX_EVEX_0FD1, PREFIX_EVEX_0FD5,
diff --git a/opcodes/i386-dis-evex-prefix.h b/opcodes/i386-dis-evex-prefix.h
index 413fd97..01998c5 100644
--- a/opcodes/i386-dis-evex-prefix.h
+++ b/opcodes/i386-dis-evex-prefix.h
@@ -1235,12 +1235,6 @@
{ Bad_Opcode },
{ VEX_W_TABLE (EVEX_W_0F3A1B_P_2) },
},
- /* PREFIX_EVEX_0F3A1D */
- {
- { Bad_Opcode },
- { Bad_Opcode },
- { VEX_W_TABLE (EVEX_W_0F3A1D_P_2) },
- },
/* PREFIX_EVEX_0F3A1E */
{
{ Bad_Opcode },
diff --git a/opcodes/i386-dis-evex-w.h b/opcodes/i386-dis-evex-w.h
index dd3caad..ed7968a 100644
--- a/opcodes/i386-dis-evex-w.h
+++ b/opcodes/i386-dis-evex-w.h
@@ -738,10 +738,6 @@
{ EVEX_LEN_TABLE (EVEX_LEN_0F3A1B_P_2_W_0) },
{ EVEX_LEN_TABLE (EVEX_LEN_0F3A1B_P_2_W_1) },
},
- /* EVEX_W_0F3A1D_P_2 */
- {
- { "vcvtps2ph", { EXxmmq, XM, EXxEVexS, Ib }, 0 },
- },
/* EVEX_W_0F3A21_P_2 */
{
{ "vinsertps", { XMM, Vex, EXxmm_md, Ib }, 0 },
diff --git a/opcodes/i386-dis-evex.h b/opcodes/i386-dis-evex.h
index 249812b..667d39d 100644
--- a/opcodes/i386-dis-evex.h
+++ b/opcodes/i386-dis-evex.h
@@ -616,7 +616,7 @@ static const struct dis386 evex_table[][256] = {
{ PREFIX_TABLE (PREFIX_EVEX_0F3A1A) },
{ PREFIX_TABLE (PREFIX_EVEX_0F3A1B) },
{ Bad_Opcode },
- { PREFIX_TABLE (PREFIX_EVEX_0F3A1D) },
+ { PREFIX_TABLE (PREFIX_VEX_0F3A1D) },
{ PREFIX_TABLE (PREFIX_EVEX_0F3A1E) },
{ PREFIX_TABLE (PREFIX_EVEX_0F3A1F) },
/* 20 */
diff --git a/opcodes/i386-dis.c b/opcodes/i386-dis.c
index 62f4281..7f521b2 100644
--- a/opcodes/i386-dis.c
+++ b/opcodes/i386-dis.c
@@ -1615,7 +1615,6 @@ enum
PREFIX_EVEX_0F3A19,
PREFIX_EVEX_0F3A1A,
PREFIX_EVEX_0F3A1B,
- PREFIX_EVEX_0F3A1D,
PREFIX_EVEX_0F3A1E,
PREFIX_EVEX_0F3A1F,
PREFIX_EVEX_0F3A20,
@@ -1910,6 +1909,7 @@ enum
VEX_W_0F380D_P_2,
VEX_W_0F380E_P_2,
VEX_W_0F380F_P_2,
+ VEX_W_0F3813_P_2,
VEX_W_0F3816_P_2,
VEX_W_0F3818_P_2,
VEX_W_0F3819_P_2,
@@ -1934,6 +1934,7 @@ enum
VEX_W_0F3A06_P_2,
VEX_W_0F3A18_P_2,
VEX_W_0F3A19_P_2,
+ VEX_W_0F3A1D_P_2,
VEX_W_0F3A30_P_2_LEN_0,
VEX_W_0F3A31_P_2_LEN_0,
VEX_W_0F3A32_P_2_LEN_0,
@@ -2110,7 +2111,6 @@ enum
EVEX_W_0F3A19_P_2,
EVEX_W_0F3A1A_P_2,
EVEX_W_0F3A1B_P_2,
- EVEX_W_0F3A1D_P_2,
EVEX_W_0F3A21_P_2,
EVEX_W_0F3A23_P_2,
EVEX_W_0F3A38_P_2,
@@ -5504,7 +5504,7 @@ static const struct dis386 prefix_table[][4] = {
{
{ Bad_Opcode },
{ Bad_Opcode },
- { "vcvtph2ps", { XM, EXxmmq }, 0 },
+ { VEX_W_TABLE (VEX_W_0F3813_P_2) },
},
/* PREFIX_VEX_0F3816 */
@@ -6326,7 +6326,7 @@ static const struct dis386 prefix_table[][4] = {
{
{ Bad_Opcode },
{ Bad_Opcode },
- { "vcvtps2ph", { EXxmmq, XM, Ib }, 0 },
+ { VEX_W_TABLE (VEX_W_0F3A1D_P_2) },
},
/* PREFIX_VEX_0F3A20 */
@@ -9903,6 +9903,10 @@ static const struct dis386 vex_w_table[][2] = {
{ "vtestpd", { XM, EXx }, 0 },
},
{
+ /* VEX_W_0F3813_P_2 */
+ { "vcvtph2ps", { XM, EXxmmq }, 0 },
+ },
+ {
/* VEX_W_0F3816_P_2 */
{ "vpermps", { XM, Vex, EXx }, 0 },
},
@@ -10001,6 +10005,10 @@ static const struct dis386 vex_w_table[][2] = {
{ "vextractf128", { EXxmm, XM, Ib }, 0 },
},
{
+ /* VEX_W_0F3A1D_P_2 */
+ { "vcvtps2ph", { EXxmmq, XM, EXxEVexS, Ib }, 0 },
+ },
+ {
/* VEX_W_0F3A30_P_2_LEN_0 */
{ MOD_TABLE (MOD_VEX_W_0_0F3A30_P_2_LEN_0) },
{ MOD_TABLE (MOD_VEX_W_1_0F3A30_P_2_LEN_0) },