summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlan Modra <amodra@bigpond.net.au>2005-11-07 00:19:12 +0000
committerAlan Modra <amodra@bigpond.net.au>2005-11-07 00:19:12 +0000
commit7bcbef46e5279bcfde66c1aac2d9b47252db223c (patch)
tree6d3e4b29bc780d2fee09297f016e7f5aec439192
parentaace2aeb9dc2b1536aec1fc3ce5b46770b8f0ab0 (diff)
downloadbinutils-redhat-7bcbef46e5279bcfde66c1aac2d9b47252db223c.tar.gz
* i386-dis.c (ckprefix): Handle rex on fwait. Don't print
ignored rex prefixes here. (print_insn): Instead, handle them similarly to fwait followed by non-fp insns.
-rw-r--r--opcodes/ChangeLog21
-rw-r--r--opcodes/i386-dis.c15
2 files changed, 22 insertions, 14 deletions
diff --git a/opcodes/ChangeLog b/opcodes/ChangeLog
index 0496dbe732..b6f5ccd3d7 100644
--- a/opcodes/ChangeLog
+++ b/opcodes/ChangeLog
@@ -1,3 +1,10 @@
+2005-11-07 Alan Modra <amodra@bigpond.net.au>
+
+ * i386-dis.c (ckprefix): Handle rex on fwait. Don't print
+ ignored rex prefixes here.
+ (print_insn): Instead, handle them similarly to fwait followed
+ by non-fp insns.
+
2005-11-02 H.J. Lu <hongjiu.lu@intel.com>
* iq2000-desc.c: Regenerated.
@@ -109,7 +116,7 @@
* configure.in: Add target architecture bfd_arch_z80.
* configure: Regenerated.
- * disassemble.c (disassembler)<ARCH_z80>: Add case
+ * disassemble.c (disassembler)<ARCH_z80>: Add case
bfd_arch_z80.
* z80-dis.c: New file.
@@ -270,7 +277,7 @@
2005-08-23 David Ung <davidu@mips.com>
* mips16-opc.c (mips16_opcodes): Add the MIPS16e jalrc/jrc
- instructions to the table.
+ instructions to the table.
2005-08-18 Alan Modra <amodra@bigpond.net.au>
@@ -405,7 +412,7 @@
* cgen-ops.h, cgen-types.h: New files.
* Makefile.am (HFILES): List them.
* Makefile.in: Regenerated.
-
+
2005-07-07 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
* arc-dis.c, arm-dis.c, cris-dis.c, crx-dis.c, d10v-dis.c,
@@ -496,7 +503,7 @@
* vax-dis.c: Likewise.
* w65-dis.c: Likewise.
* z8kgen.c: Likewise.
-
+
* fr30-*: Regenerate.
* frv-*: Regenerate.
* ip2k-*: Regenerate.
@@ -513,13 +520,13 @@
2005-06-16 David Ung <davidu@mips.com>
- * mips16-opc.c (mips16_opcodes): Add the following MIPS16e
- instructions to the table; seb/seh/sew/zeb/zeh/zew.
+ * mips16-opc.c (mips16_opcodes): Add the following MIPS16e
+ instructions to the table; seb/seh/sew/zeb/zeh/zew.
2005-06-15 Dave Brolley <brolley@redhat.com>
Contribute Morpho ms1 on behalf of Red Hat
- * ms1-asm.c, ms1-desc.c, ms1-dis.c, ms1-ibld.c, ms1-opc.c,
+ * ms1-asm.c, ms1-desc.c, ms1-dis.c, ms1-ibld.c, ms1-opc.c,
ms1-opc.h: New files, Morpho ms1 target.
2004-05-14 Stan Cox <scox@redhat.com>
diff --git a/opcodes/i386-dis.c b/opcodes/i386-dis.c
index a3b205a49d..47455e37e4 100644
--- a/opcodes/i386-dis.c
+++ b/opcodes/i386-dis.c
@@ -1814,7 +1814,7 @@ ckprefix (void)
/* fwait is really an instruction. If there are prefixes
before the fwait, they belong to the fwait, *not* to the
following instruction. */
- if (prefixes)
+ if (prefixes || rex)
{
prefixes |= PREFIX_FWAIT;
codep++;
@@ -1828,8 +1828,8 @@ ckprefix (void)
/* Rex is ignored when followed by another prefix. */
if (rex)
{
- oappend (prefix_name (rex, 0));
- oappend (" ");
+ rex_used = rex;
+ return;
}
rex = newrex;
codep++;
@@ -2117,13 +2117,14 @@ print_insn (bfd_vma pc, disassemble_info *info)
FETCH_DATA (info, codep + 1);
two_source_ops = (*codep == 0x62) || (*codep == 0xc8);
- if ((prefixes & PREFIX_FWAIT)
- && ((*codep < 0xd8) || (*codep > 0xdf)))
+ if (((prefixes & PREFIX_FWAIT)
+ && ((*codep < 0xd8) || (*codep > 0xdf)))
+ || (rex && rex_used))
{
const char *name;
- /* fwait not followed by floating point instruction. Print the
- first prefix, which is probably fwait itself. */
+ /* fwait not followed by floating point instruction, or rex followed
+ by other prefixes. Print the first prefix. */
name = prefix_name (priv.the_buffer[0], priv.orig_sizeflag);
if (name == NULL)
name = INTERNAL_DISASSEMBLER_ERROR;