+2018-09-14 H.J. Lu <hongjiu.lu@intel.com>
+
+ PR binutils/23655
+ * testsuite/gas/i386/evex.d: New file.
+ * testsuite/gas/i386/evex.s: Likewise.
+ * testsuite/gas/i386/i386.exp: Run evex.
+
2018-09-10 Lifang Xia <lifang_xia@c-sky.com>
* config/tc-csky.c (md_apply_fix): Transmit BFD_RELOC_32_PCREL to
--- /dev/null
+#objdump: -dw -Msuffix
+#name: i386 EVX insns
+
+.*: +file format .*
+
+
+Disassembly of section .text:
+
+0+ <_start>:
+ +[a-f0-9]+: 62 f1 d6 38 2a f0 vcvtsi2ssl %eax,\{rd-sae\},%xmm5,%xmm6
+ +[a-f0-9]+: 62 f1 d7 38 2a f0 vcvtsi2sdl %eax,\{rd-sae\},%xmm5,%xmm6
+ +[a-f0-9]+: 62 f1 d6 08 7b f0 vcvtusi2ssl %eax,%xmm5,%xmm6
+ +[a-f0-9]+: 62 f1 d7 08 7b f0 vcvtusi2sdl %eax,%xmm5,%xmm6
+ +[a-f0-9]+: 62 f1 d6 38 7b f0 vcvtusi2ssl %eax,\{rd-sae\},%xmm5,%xmm6
+ +[a-f0-9]+: 62 f1 d7 38 7b f0 vcvtusi2sdl %eax,\{rd-sae\},%xmm5,%xmm6
+#pass
--- /dev/null
+# Check EVEX instructions
+
+ .allow_index_reg
+ .text
+_start:
+ .byte 0x62, 0xf1, 0xd6, 0x38, 0x2a, 0xf0
+ .byte 0x62, 0xf1, 0xd7, 0x38, 0x2a, 0xf0
+ .byte 0x62, 0xf1, 0xd6, 0x08, 0x7b, 0xf0
+ .byte 0x62, 0xf1, 0xd7, 0x08, 0x7b, 0xf0
+ .byte 0x62, 0xf1, 0xd6, 0x38, 0x7b, 0xf0
+ .byte 0x62, 0xf1, 0xd7, 0x38, 0x7b, 0xf0
run_dump_test "avx512er-intel"
run_dump_test "avx512pf"
run_dump_test "avx512pf-intel"
+ run_dump_test "evex"
run_dump_test "evex-lig256"
run_dump_test "evex-lig512"
run_dump_test "evex-lig256-intel"
2018-09-14 H.J. Lu <hongjiu.lu@intel.com>
+ PR binutils/23655
+ * i386-dis-evex.h (evex_table): Replace Eq with Edqa for
+ vcvtsi2ss%LQ, vcvtsi2sd%LQ, vcvtusi2ss%LQ and vcvtusi2sd%LQ.
+ * i386-dis.c (Edqa): New.
+ (dqa_mode): Likewise.
+ (intel_operand_size): Handle dqa_mode as m_mode.
+ (OP_E_register): Handle dqa_mode as dq_mode.
+ (OP_E_memory): Set shift for dqa_mode based on address_mode.
+
+2018-09-14 H.J. Lu <hongjiu.lu@intel.com>
+
* i386-dis.c (OP_E_memory): Reformat.
2018-09-14 Jan Beulich <jbeulich@suse.com>
/* EVEX_W_0F2A_P_1 */
{
{ "vcvtsi2ss%LQ", { XMScalar, VexScalar, EXxEVexR, Ed }, 0 },
- { "vcvtsi2ss%LQ", { XMScalar, VexScalar, EXxEVexR, Eq }, 0 },
+ { "vcvtsi2ss%LQ", { XMScalar, VexScalar, EXxEVexR, Edqa }, 0 },
},
/* EVEX_W_0F2A_P_3 */
{
{ "vcvtsi2sd%LQ", { XMScalar, VexScalar, Ed }, 0 },
- { "vcvtsi2sd%LQ", { XMScalar, VexScalar, EXxEVexR, Eq }, 0 },
+ { "vcvtsi2sd%LQ", { XMScalar, VexScalar, EXxEVexR, Edqa }, 0 },
},
/* EVEX_W_0F2B_P_0 */
{
/* EVEX_W_0F7B_P_1 */
{
{ "vcvtusi2ss%LQ", { XMScalar, VexScalar, EXxEVexR, Ed }, 0 },
- { "vcvtusi2ss%LQ", { XMScalar, VexScalar, EXxEVexR, Eq }, 0 },
+ { "vcvtusi2ss%LQ", { XMScalar, VexScalar, EXxEVexR, Edqa }, 0 },
},
/* EVEX_W_0F7B_P_2 */
{
/* EVEX_W_0F7B_P_3 */
{
{ "vcvtusi2sd%LQ", { XMScalar, VexScalar, Ed }, 0 },
- { "vcvtusi2sd%LQ", { XMScalar, VexScalar, EXxEVexR, Eq }, 0 },
+ { "vcvtusi2sd%LQ", { XMScalar, VexScalar, EXxEVexR, Edqa }, 0 },
},
/* EVEX_W_0F7E_P_1 */
{
#define Edb { OP_E, db_mode }
#define Edw { OP_E, dw_mode }
#define Edqd { OP_E, dqd_mode }
+#define Edqa { OP_E, dqa_mode }
#define Eq { OP_E, q_mode }
#define indirEv { OP_indirE, indir_v_mode }
#define indirEp { OP_indirE, f_mode }
dw_mode,
/* registers like dq_mode, memory like d_mode. */
dqd_mode,
+ /* operand size depends on the W bit as well as address mode. */
+ dqa_mode,
/* normal vex mode */
vex_mode,
/* 128bit vex mode */
case q_swap_mode:
oappend ("QWORD PTR ");
break;
+ case dqa_mode:
case m_mode:
if (address_mode == mode_64bit)
oappend ("QWORD PTR ");
case dqb_mode:
case dqd_mode:
case dqw_mode:
+ case dqa_mode:
USED_REX (REX_W);
if (rex & REX_W)
names = names64;
case xmm_mb_mode:
shift = 0;
break;
+ case dqa_mode:
+ shift = address_mode == mode_64bit ? 3 : 2;
+ break;
default:
abort ();
}