mirror of
https://sourceware.org/git/binutils-gdb.git
synced 2024-11-23 18:14:13 +08:00
Replace VexNDS, VexNDD and VexLWP with VexVVVV.
gas/ 2009-12-19 H.J. Lu <hongjiu.lu@intel.com> * config/tc-i386.c (process_operands): Check vexvvvv instead of vexnds and vexndd. (build_modrm_byte): Check vexvvvv instead of vexnds, vexndd and vexlwp. opcodes/ 2009-12-19 H.J. Lu <hongjiu.lu@intel.com> * i386-gen.c (opcode_modifiers): Remove VexNDS, VexNDD and VexLWP. Add VexVVVV. * i386-opc.h (VexNDS): Removed. (VexNDD): Likewise. (VexLWP): Likewise. (VEXXDS): New. (VEXNDD): Likewise. (VEXLWP): Likewise. (VexVVVV): Likewise. (i386_opcode_modifier): Remove vexnds, vexndd and vexlwp. Add vexvvvv. * i386-opc.tbl: Replace VexNDS with VexVVVV=1, VexNDD with VexVVVV=2 and VexLWP with VexVVVV=3. * i386-tbl.h: Regenerated.
This commit is contained in:
parent
e946488510
commit
2426c15ff8
@ -1,3 +1,10 @@
|
||||
2009-12-19 H.J. Lu <hongjiu.lu@intel.com>
|
||||
|
||||
* config/tc-i386.c (process_operands): Check vexvvvv instead
|
||||
of vexnds and vexndd.
|
||||
(build_modrm_byte): Check vexvvvv instead of vexnds, vexndd
|
||||
and vexlwp.
|
||||
|
||||
2009-12-19 Maciej W. Rozycki <macro@codesourcery.com>
|
||||
|
||||
* config/tc-mips.c (s_mips_ent): Also set BSF_FUNCTION for
|
||||
|
@ -4713,9 +4713,7 @@ process_operands (void)
|
||||
unnecessary segment overrides. */
|
||||
const seg_entry *default_seg = 0;
|
||||
|
||||
if (i.tm.opcode_modifier.sse2avx
|
||||
&& (i.tm.opcode_modifier.vexnds
|
||||
|| i.tm.opcode_modifier.vexndd))
|
||||
if (i.tm.opcode_modifier.sse2avx && i.tm.opcode_modifier.vexvvvv)
|
||||
{
|
||||
unsigned int dupl = i.operands;
|
||||
unsigned int dest = dupl - 1;
|
||||
@ -4959,7 +4957,7 @@ build_modrm_byte (void)
|
||||
It must have VexNDS and VexImmExt. */
|
||||
gas_assert ((i.reg_operands == 4
|
||||
|| (i.reg_operands == 3 && i.mem_operands == 1))
|
||||
&& i.tm.opcode_modifier.vexnds
|
||||
&& i.tm.opcode_modifier.vexvvvv == VEXXDS
|
||||
&& i.tm.opcode_modifier.veximmext
|
||||
&& (operand_type_equal (&i.tm.operand_types[dest], ®xmm)
|
||||
|| operand_type_equal (&i.tm.operand_types[dest], ®ymm)));
|
||||
@ -5005,10 +5003,9 @@ build_modrm_byte (void)
|
||||
a instruction with VEX prefix and 3 sources. */
|
||||
if (i.mem_operands == 0
|
||||
&& ((i.reg_operands == 2
|
||||
&& !i.tm.opcode_modifier.vexndd
|
||||
&& !i.tm.opcode_modifier.vexlwp)
|
||||
&& i.tm.opcode_modifier.vexvvvv <= VEXXDS)
|
||||
|| (i.reg_operands == 3
|
||||
&& i.tm.opcode_modifier.vexnds)
|
||||
&& i.tm.opcode_modifier.vexvvvv == VEXXDS)
|
||||
|| (i.reg_operands == 4 && vex_3_sources)))
|
||||
{
|
||||
switch (i.operands)
|
||||
@ -5023,7 +5020,7 @@ build_modrm_byte (void)
|
||||
is an instruction with VexNDS. */
|
||||
gas_assert (i.imm_operands == 1
|
||||
|| (i.imm_operands == 0
|
||||
&& (i.tm.opcode_modifier.vexnds
|
||||
&& (i.tm.opcode_modifier.vexvvvv == VEXXDS
|
||||
|| i.types[0].bitfield.shiftcount)));
|
||||
if (operand_type_check (i.types[0], imm)
|
||||
|| i.types[0].bitfield.shiftcount)
|
||||
@ -5042,11 +5039,11 @@ build_modrm_byte (void)
|
||||
gas_assert ((i.imm_operands == 2
|
||||
&& i.types[0].bitfield.imm8
|
||||
&& i.types[1].bitfield.imm8)
|
||||
|| (i.tm.opcode_modifier.vexnds
|
||||
|| (i.tm.opcode_modifier.vexvvvv == VEXXDS
|
||||
&& i.imm_operands == 1
|
||||
&& (i.types[0].bitfield.imm8
|
||||
|| i.types[i.operands - 1].bitfield.imm8)));
|
||||
if (i.tm.opcode_modifier.vexnds)
|
||||
if (i.tm.opcode_modifier.vexvvvv == VEXXDS)
|
||||
{
|
||||
if (i.types[0].bitfield.imm8)
|
||||
source = 1;
|
||||
@ -5066,7 +5063,7 @@ build_modrm_byte (void)
|
||||
{
|
||||
dest = source + 1;
|
||||
|
||||
if (i.tm.opcode_modifier.vexnds)
|
||||
if (i.tm.opcode_modifier.vexvvvv == VEXXDS)
|
||||
{
|
||||
/* For instructions with VexNDS, the register-only
|
||||
source operand must be XMM or YMM register. It is
|
||||
@ -5356,7 +5353,7 @@ build_modrm_byte (void)
|
||||
i.rex |= REX_B;
|
||||
}
|
||||
}
|
||||
else if (i.tm.opcode_modifier.vexlwp)
|
||||
else if (i.tm.opcode_modifier.vexvvvv == VEXLWP)
|
||||
{
|
||||
i.vex.register_specifier = i.op[2].regs;
|
||||
if (!i.mem_operands)
|
||||
@ -5393,7 +5390,7 @@ build_modrm_byte (void)
|
||||
|
||||
if (vex_3_sources)
|
||||
op = dest;
|
||||
else if (i.tm.opcode_modifier.vexnds)
|
||||
else if (i.tm.opcode_modifier.vexvvvv == VEXXDS)
|
||||
{
|
||||
/* For instructions with VexNDS, the register-only
|
||||
source operand is encoded in VEX prefix. */
|
||||
@ -5410,7 +5407,7 @@ build_modrm_byte (void)
|
||||
gas_assert (vex_reg < i.operands);
|
||||
}
|
||||
}
|
||||
else if (i.tm.opcode_modifier.vexndd)
|
||||
else if (i.tm.opcode_modifier.vexvvvv == VEXNDD)
|
||||
{
|
||||
/* For instructions with VexNDD, there should be
|
||||
no memory operand and the register destination
|
||||
|
@ -1,3 +1,22 @@
|
||||
2009-12-19 H.J. Lu <hongjiu.lu@intel.com>
|
||||
|
||||
* i386-gen.c (opcode_modifiers): Remove VexNDS, VexNDD and
|
||||
VexLWP. Add VexVVVV.
|
||||
|
||||
* i386-opc.h (VexNDS): Removed.
|
||||
(VexNDD): Likewise.
|
||||
(VexLWP): Likewise.
|
||||
(VEXXDS): New.
|
||||
(VEXNDD): Likewise.
|
||||
(VEXLWP): Likewise.
|
||||
(VexVVVV): Likewise.
|
||||
(i386_opcode_modifier): Remove vexnds, vexndd and vexlwp.
|
||||
Add vexvvvv.
|
||||
|
||||
* i386-opc.tbl: Replace VexNDS with VexVVVV=1, VexNDD with
|
||||
VexVVVV=2 and VexLWP with VexVVVV=3.
|
||||
* i386-tbl.h: Regenerated.
|
||||
|
||||
2009-12-18 H.J. Lu <hongjiu.lu@intel.com>
|
||||
|
||||
* i386-gen.c (operand_types): Move Imm1 before Imm8.
|
||||
|
@ -353,9 +353,7 @@ static bitfield opcode_modifiers[] =
|
||||
BITFIELD (Rex64),
|
||||
BITFIELD (Ugh),
|
||||
BITFIELD (Vex),
|
||||
BITFIELD (VexNDS),
|
||||
BITFIELD (VexNDD),
|
||||
BITFIELD (VexLWP),
|
||||
BITFIELD (VexVVVV),
|
||||
BITFIELD (VexW),
|
||||
BITFIELD (VexOpcode),
|
||||
BITFIELD (VexSources),
|
||||
|
@ -275,15 +275,23 @@ enum
|
||||
#define VEX128 1
|
||||
#define VEX256 2
|
||||
Vex,
|
||||
/* insn has VEX NDS. Register-only source is encoded in Vex prefix.
|
||||
We use VexNDS on insns with VEX DDS since the register-only source
|
||||
is the second source register. */
|
||||
VexNDS,
|
||||
/* insn has VEX NDD. Register destination is encoded in Vex prefix. */
|
||||
VexNDD,
|
||||
/* insn has VEX NDD. Register destination is encoded in Vex prefix
|
||||
and one of the operands can access a memory location. */
|
||||
VexLWP,
|
||||
/* How to encode VEX.vvvv:
|
||||
0: VEX.vvvv must be 1111b.
|
||||
1: VEX.DNS. Register-only source is encoded in VEX.vvvv where
|
||||
the content of source registers will be preserved.
|
||||
VEX.DDS. The second register operand is encoded in VEX.vvvv
|
||||
where the content of first source register will be overwritten
|
||||
by the result.
|
||||
For assembler, there are no difference between VEX.DNS and
|
||||
VEX.DDS.
|
||||
2. VEX.NDD. Register destination is encoded in VEX.vvvv.
|
||||
3. VEX.LWP. Register destination is encoded in VEX.vvvv and one
|
||||
of the operands can access a memory location.
|
||||
*/
|
||||
#define VEXXDS 1
|
||||
#define VEXNDD 2
|
||||
#define VEXLWP 3
|
||||
VexVVVV,
|
||||
/* How the VEX.W bit is used:
|
||||
0: Set by the REX.W bit.
|
||||
1: VEX.W0. Should always be 0.
|
||||
@ -373,9 +381,7 @@ typedef struct i386_opcode_modifier
|
||||
unsigned int rex64:1;
|
||||
unsigned int ugh:1;
|
||||
unsigned int vex:2;
|
||||
unsigned int vexnds:1;
|
||||
unsigned int vexndd:1;
|
||||
unsigned int vexlwp:1;
|
||||
unsigned int vexvvvv:2;
|
||||
unsigned int vexw:2;
|
||||
unsigned int vexopcode:3;
|
||||
unsigned int vexsources:2;
|
||||
|
1688
opcodes/i386-opc.tbl
1688
opcodes/i386-opc.tbl
File diff suppressed because it is too large
Load Diff
6984
opcodes/i386-tbl.h
6984
opcodes/i386-tbl.h
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue
Block a user