include/opcode/
* i386.h (i386_optab): Remove fildd, fistpd and fisttpd. opcodes/ * i386-dis.c (x_mode): Comment. (two_source_ops): File scope. (float_mem): Correct fisttpll and fistpll. (float_mem_mode): New table. (dofloat): Use it. (OP_E): Correct intel mode PTR output. (ptr_reg): Use open_char and close_char. (PNI_Fixup): Handle possible suffix on sidt. Use op1out etc. for operands. Set two_source_ops. gas/testsuite/ * gas/i386/prescott.s: Remove fisttpd and fisttpq. * gas/i386/prescott.d: Update.
This commit is contained in:
parent
95b6a1f268
commit
1d9f512f33
7 changed files with 147 additions and 51 deletions
|
@ -1,3 +1,8 @@
|
|||
2004-06-24 Alan Modra <amodra@bigpond.net.au>
|
||||
|
||||
* gas/i386/prescott.s: Remove fisttpd and fisttpq.
|
||||
* gas/i386/prescott.d: Update.
|
||||
|
||||
2004-06-08 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
* gas/ia64/dv-raw-err.s: Add some new postinc tests.
|
||||
|
|
|
@ -13,25 +13,24 @@ Disassembly of section .text:
|
|||
10: df 88 90 90 90 90 [ ]*fisttp 0x90909090\(%eax\)
|
||||
16: db 88 90 90 90 90 [ ]*fisttpl 0x90909090\(%eax\)
|
||||
1c: dd 88 90 90 90 90 [ ]*fisttpll 0x90909090\(%eax\)
|
||||
22: dd 88 90 90 90 90 [ ]*fisttpll 0x90909090\(%eax\)
|
||||
28: dd 88 90 90 90 90 [ ]*fisttpll 0x90909090\(%eax\)
|
||||
2e: 66 0f 7c 65 00 [ ]*haddpd 0x0\(%ebp\),%xmm4
|
||||
33: 66 0f 7c ee [ ]*haddpd %xmm6,%xmm5
|
||||
37: f2 0f 7c 37 [ ]*haddps \(%edi\),%xmm6
|
||||
3b: f2 0f 7c f8 [ ]*haddps %xmm0,%xmm7
|
||||
3f: 66 0f 7d c1 [ ]*hsubpd %xmm1,%xmm0
|
||||
43: 66 0f 7d 0a [ ]*hsubpd \(%edx\),%xmm1
|
||||
47: f2 0f 7d d2 [ ]*hsubps %xmm2,%xmm2
|
||||
4b: f2 0f 7d 1c 24 [ ]*hsubps \(%esp\),%xmm3
|
||||
50: f2 0f f0 2e [ ]*lddqu \(%esi\),%xmm5
|
||||
54: 0f 01 c8 [ ]*monitor %eax,%ecx,%edx
|
||||
57: 0f 01 c8 [ ]*monitor %eax,%ecx,%edx
|
||||
5a: f2 0f 12 f7 [ ]*movddup %xmm7,%xmm6
|
||||
5e: f2 0f 12 38 [ ]*movddup \(%eax\),%xmm7
|
||||
62: f3 0f 16 01 [ ]*movshdup \(%ecx\),%xmm0
|
||||
66: f3 0f 16 ca [ ]*movshdup %xmm2,%xmm1
|
||||
6a: f3 0f 12 13 [ ]*movsldup \(%ebx\),%xmm2
|
||||
6e: f3 0f 12 dc [ ]*movsldup %xmm4,%xmm3
|
||||
72: 0f 01 c9 [ ]*mwait %eax,%ecx
|
||||
75: 0f 01 c9 [ ]*mwait %eax,%ecx
|
||||
22: 66 0f 7c 65 00 [ ]*haddpd 0x0\(%ebp\),%xmm4
|
||||
27: 66 0f 7c ee [ ]*haddpd %xmm6,%xmm5
|
||||
2b: f2 0f 7c 37 [ ]*haddps \(%edi\),%xmm6
|
||||
2f: f2 0f 7c f8 [ ]*haddps %xmm0,%xmm7
|
||||
33: 66 0f 7d c1 [ ]*hsubpd %xmm1,%xmm0
|
||||
37: 66 0f 7d 0a [ ]*hsubpd \(%edx\),%xmm1
|
||||
3b: f2 0f 7d d2 [ ]*hsubps %xmm2,%xmm2
|
||||
3f: f2 0f 7d 1c 24 [ ]*hsubps \(%esp\),%xmm3
|
||||
44: f2 0f f0 2e [ ]*lddqu \(%esi\),%xmm5
|
||||
48: 0f 01 c8 [ ]*monitor %eax,%ecx,%edx
|
||||
4b: 0f 01 c8 [ ]*monitor %eax,%ecx,%edx
|
||||
4e: f2 0f 12 f7 [ ]*movddup %xmm7,%xmm6
|
||||
52: f2 0f 12 38 [ ]*movddup \(%eax\),%xmm7
|
||||
56: f3 0f 16 01 [ ]*movshdup \(%ecx\),%xmm0
|
||||
5a: f3 0f 16 ca [ ]*movshdup %xmm2,%xmm1
|
||||
5e: f3 0f 12 13 [ ]*movsldup \(%ebx\),%xmm2
|
||||
62: f3 0f 12 dc [ ]*movsldup %xmm4,%xmm3
|
||||
66: 0f 01 c9 [ ]*mwait %eax,%ecx
|
||||
69: 0f 01 c9 [ ]*mwait %eax,%ecx
|
||||
6c: 00 00 [ ]*add %al,\(%eax\)
|
||||
...
|
||||
|
|
|
@ -8,8 +8,6 @@ foo:
|
|||
addsubps %xmm4,%xmm3
|
||||
fisttp 0x90909090(%eax)
|
||||
fisttpl 0x90909090(%eax)
|
||||
fisttpd 0x90909090(%eax)
|
||||
fisttpq 0x90909090(%eax)
|
||||
fisttpll 0x90909090(%eax)
|
||||
haddpd 0x0(%ebp),%xmm4
|
||||
haddpd %xmm6,%xmm5
|
||||
|
|
|
@ -1,3 +1,7 @@
|
|||
2004-06-24 Alan Modra <amodra@bigpond.net.au>
|
||||
|
||||
* i386.h (i386_optab): Remove fildd, fistpd and fisttpd.
|
||||
|
||||
2004-05-24 Peter Barada <peter@the-baradas.com>
|
||||
|
||||
* m68k.h: Add 'size' to m68k_opcode.
|
||||
|
|
|
@ -583,7 +583,6 @@ static const template i386_optab[] = {
|
|||
{"fld", 1, 0xdb, 5, 0, x_FP|Modrm, { LLongMem, 0, 0} },
|
||||
{"fild", 1, 0xdf, 0, 0, sl_FP|FloatMF|Modrm, { ShortMem|LongMem, 0, 0} },
|
||||
/* Intel Syntax */
|
||||
{"fildd", 1, 0xdf, 5, 0, FP|Modrm, { LLongMem, 0, 0} },
|
||||
{"fildq", 1, 0xdf, 5, 0, FP|Modrm, { LLongMem, 0, 0} },
|
||||
{"fildll", 1, 0xdf, 5, 0, FP|Modrm, { LLongMem, 0, 0} },
|
||||
{"fldt", 1, 0xdb, 5, 0, FP|Modrm, { LLongMem, 0, 0} },
|
||||
|
@ -603,7 +602,6 @@ static const template i386_optab[] = {
|
|||
{"fstp", 1, 0xdb, 7, 0, x_FP|Modrm, { LLongMem, 0, 0} },
|
||||
{"fistp", 1, 0xdf, 3, 0, sl_FP|FloatMF|Modrm, { ShortMem|LongMem, 0, 0} },
|
||||
/* Intel Syntax */
|
||||
{"fistpd", 1, 0xdf, 7, 0, FP|Modrm, { LLongMem, 0, 0} },
|
||||
{"fistpq", 1, 0xdf, 7, 0, FP|Modrm, { LLongMem, 0, 0} },
|
||||
{"fistpll",1, 0xdf, 7, 0, FP|Modrm, { LLongMem, 0, 0} },
|
||||
{"fstpt", 1, 0xdb, 7, 0, FP|Modrm, { LLongMem, 0, 0} },
|
||||
|
@ -1308,7 +1306,6 @@ static const template i386_optab[] = {
|
|||
{"addsubps", 2, 0xf20fd0, X, CpuPNI, FP|Modrm, { RegXMM|LLongMem, RegXMM, 0 } },
|
||||
{"fisttp", 1, 0xdf, 1, CpuPNI, sl_FP|FloatMF|Modrm, { ShortMem|LongMem, 0, 0} },
|
||||
/* Intel Syntax */
|
||||
{"fisttpd", 1, 0xdd, 1, CpuPNI, FP|Modrm, { LLongMem, 0, 0} },
|
||||
{"fisttpq", 1, 0xdd, 1, CpuPNI, FP|Modrm, { LLongMem, 0, 0} },
|
||||
{"fisttpll", 1, 0xdd, 1, CpuPNI, FP|Modrm, { LLongMem, 0, 0} },
|
||||
{"haddpd", 2, 0x660f7c, X, CpuPNI, FP|Modrm, { RegXMM|LLongMem, RegXMM, 0 } },
|
||||
|
|
|
@ -1,3 +1,15 @@
|
|||
2004-06-24 Alan Modra <amodra@bigpond.net.au>
|
||||
|
||||
* i386-dis.c (x_mode): Comment.
|
||||
(two_source_ops): File scope.
|
||||
(float_mem): Correct fisttpll and fistpll.
|
||||
(float_mem_mode): New table.
|
||||
(dofloat): Use it.
|
||||
(OP_E): Correct intel mode PTR output.
|
||||
(ptr_reg): Use open_char and close_char.
|
||||
(PNI_Fixup): Handle possible suffix on sidt. Use op1out etc. for
|
||||
operands. Set two_source_ops.
|
||||
|
||||
2004-06-15 Alan Modra <amodra@bigpond.net.au>
|
||||
|
||||
* arc-ext.c (build_ARC_extmap): Use bfd_get_section_size
|
||||
|
|
|
@ -312,7 +312,7 @@ fetch_data (struct disassemble_info *info, bfd_byte *addr)
|
|||
#define w_mode 3 /* word operand */
|
||||
#define d_mode 4 /* double word operand */
|
||||
#define q_mode 5 /* quad word operand */
|
||||
#define x_mode 6
|
||||
#define x_mode 6 /* 80 bit float operand */
|
||||
#define m_mode 7 /* d_mode in 32bit, q_mode in 64bit mode. */
|
||||
#define cond_jump_mode 8
|
||||
#define loop_jcxz_mode 9
|
||||
|
@ -1881,6 +1881,7 @@ prefix_name (int pref, int sizeflag)
|
|||
|
||||
static char op1out[100], op2out[100], op3out[100];
|
||||
static int op_ad, op_index[3];
|
||||
static int two_source_ops;
|
||||
static bfd_vma op_address[3];
|
||||
static bfd_vma op_riprel[3];
|
||||
static bfd_vma start_pc;
|
||||
|
@ -1932,7 +1933,6 @@ print_insn (bfd_vma pc, disassemble_info *info)
|
|||
{
|
||||
const struct dis386 *dp;
|
||||
int i;
|
||||
int two_source_ops;
|
||||
char *first, *second, *third;
|
||||
int needcomma;
|
||||
unsigned char uses_SSE_prefix;
|
||||
|
@ -2364,7 +2364,7 @@ static const char *float_mem[] = {
|
|||
"fdivr{l||l|}",
|
||||
/* dd */
|
||||
"fld{l||l|}",
|
||||
"fisttpll",
|
||||
"fisttp{ll||ll|}",
|
||||
"fst{l||l|}",
|
||||
"fstp{l||l|}",
|
||||
"frstor",
|
||||
|
@ -2388,7 +2388,82 @@ static const char *float_mem[] = {
|
|||
"fbld",
|
||||
"fild{ll||ll|}",
|
||||
"fbstp",
|
||||
"fistpll",
|
||||
"fistp{ll||ll|}",
|
||||
};
|
||||
|
||||
static const unsigned char float_mem_mode[] = {
|
||||
/* d8 */
|
||||
d_mode,
|
||||
d_mode,
|
||||
d_mode,
|
||||
d_mode,
|
||||
d_mode,
|
||||
d_mode,
|
||||
d_mode,
|
||||
d_mode,
|
||||
/* d9 */
|
||||
d_mode,
|
||||
0,
|
||||
d_mode,
|
||||
d_mode,
|
||||
0,
|
||||
w_mode,
|
||||
0,
|
||||
w_mode,
|
||||
/* da */
|
||||
d_mode,
|
||||
d_mode,
|
||||
d_mode,
|
||||
d_mode,
|
||||
d_mode,
|
||||
d_mode,
|
||||
d_mode,
|
||||
d_mode,
|
||||
/* db */
|
||||
d_mode,
|
||||
d_mode,
|
||||
d_mode,
|
||||
d_mode,
|
||||
0,
|
||||
x_mode,
|
||||
0,
|
||||
x_mode,
|
||||
/* dc */
|
||||
q_mode,
|
||||
q_mode,
|
||||
q_mode,
|
||||
q_mode,
|
||||
q_mode,
|
||||
q_mode,
|
||||
q_mode,
|
||||
q_mode,
|
||||
/* dd */
|
||||
q_mode,
|
||||
q_mode,
|
||||
q_mode,
|
||||
q_mode,
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
w_mode,
|
||||
/* de */
|
||||
w_mode,
|
||||
w_mode,
|
||||
w_mode,
|
||||
w_mode,
|
||||
w_mode,
|
||||
w_mode,
|
||||
w_mode,
|
||||
w_mode,
|
||||
/* df */
|
||||
w_mode,
|
||||
w_mode,
|
||||
w_mode,
|
||||
w_mode,
|
||||
x_mode,
|
||||
q_mode,
|
||||
x_mode,
|
||||
q_mode
|
||||
};
|
||||
|
||||
#define ST OP_ST, 0
|
||||
|
@ -2567,14 +2642,11 @@ dofloat (int sizeflag)
|
|||
|
||||
if (mod != 3)
|
||||
{
|
||||
putop (float_mem[(floatop - 0xd8) * 8 + reg], sizeflag);
|
||||
int fp_indx = (floatop - 0xd8) * 8 + reg;
|
||||
|
||||
putop (float_mem[fp_indx], sizeflag);
|
||||
obufp = op1out;
|
||||
if (floatop == 0xdb)
|
||||
OP_E (x_mode, sizeflag);
|
||||
else if (floatop == 0xdd)
|
||||
OP_E (d_mode, sizeflag);
|
||||
else
|
||||
OP_E (v_mode, sizeflag);
|
||||
OP_E (float_mem_mode[fp_indx], sizeflag);
|
||||
return;
|
||||
}
|
||||
/* Skip mod/rm byte. */
|
||||
|
@ -3135,9 +3207,15 @@ OP_E (int bytemode, int sizeflag)
|
|||
oappend ("WORD PTR ");
|
||||
break;
|
||||
case v_mode:
|
||||
oappend ("DWORD PTR ");
|
||||
if (sizeflag & DFLAG)
|
||||
oappend ("DWORD PTR ");
|
||||
else
|
||||
oappend ("WORD PTR ");
|
||||
break;
|
||||
case d_mode:
|
||||
oappend ("DWORD PTR ");
|
||||
break;
|
||||
case q_mode:
|
||||
oappend ("QWORD PTR ");
|
||||
break;
|
||||
case m_mode:
|
||||
|
@ -3776,11 +3854,8 @@ static void
|
|||
ptr_reg (int code, int sizeflag)
|
||||
{
|
||||
const char *s;
|
||||
if (intel_syntax)
|
||||
oappend ("[");
|
||||
else
|
||||
oappend ("(");
|
||||
|
||||
*obufp++ = open_char;
|
||||
USED_REX (REX_MODE64);
|
||||
if (rex & REX_MODE64)
|
||||
{
|
||||
|
@ -3794,10 +3869,8 @@ ptr_reg (int code, int sizeflag)
|
|||
else
|
||||
s = names16[code - eAX_reg];
|
||||
oappend (s);
|
||||
if (intel_syntax)
|
||||
oappend ("]");
|
||||
else
|
||||
oappend (")");
|
||||
*obufp++ = close_char;
|
||||
*obufp = 0;
|
||||
}
|
||||
|
||||
static void
|
||||
|
@ -4162,21 +4235,29 @@ SIMD_Fixup (int extrachar, int sizeflag ATTRIBUTE_UNUSED)
|
|||
static void
|
||||
PNI_Fixup (int extrachar ATTRIBUTE_UNUSED, int sizeflag)
|
||||
{
|
||||
if (mod == 3 && reg == 1)
|
||||
if (mod == 3 && reg == 1 && rm <= 1)
|
||||
{
|
||||
char *p = obuf + strlen (obuf);
|
||||
|
||||
/* Override "sidt". */
|
||||
char *p = obuf + strlen (obuf) - 4;
|
||||
|
||||
/* We might have a suffix. */
|
||||
if (*p == 'i')
|
||||
--p;
|
||||
|
||||
if (rm)
|
||||
{
|
||||
/* mwait %eax,%ecx */
|
||||
strcpy (p - 4, "mwait %eax,%ecx");
|
||||
strcpy (p, "mwait");
|
||||
}
|
||||
else
|
||||
{
|
||||
/* monitor %eax,%ecx,%edx" */
|
||||
strcpy (p - 4, "monitor %eax,%ecx,%edx");
|
||||
strcpy (p, "monitor");
|
||||
strcpy (op3out, names32[2]);
|
||||
}
|
||||
strcpy (op1out, names32[0]);
|
||||
strcpy (op2out, names32[1]);
|
||||
two_source_ops = 1;
|
||||
|
||||
codep++;
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue