aboutsummaryrefslogtreecommitdiff
path: root/opcodes/i386-dis.c
diff options
context:
space:
mode:
authorJan Beulich <jbeulich@novell.com>2005-04-01 16:06:40 +0000
committerJan Beulich <jbeulich@novell.com>2005-04-01 16:06:40 +0000
commit6128c599eda228149fba00fe9d06361dd3a8490c (patch)
tree7ff1224ff38667002da3f36ed3305a0fdb49fcd3 /opcodes/i386-dis.c
parent373ff435a8f7f34725507ede084998d63d80d624 (diff)
downloadgdb-6128c599eda228149fba00fe9d06361dd3a8490c.zip
gdb-6128c599eda228149fba00fe9d06361dd3a8490c.tar.gz
gdb-6128c599eda228149fba00fe9d06361dd3a8490c.tar.bz2
opcodes/
2005-04-01 Jan Beulich <jbeulich@novell.com> * i386-dis.c (PNI_Fixup): Neither mwait nor monitor have any visible operands in Intel mode. The first operand of monitor is %rax in 64-bit mode.
Diffstat (limited to 'opcodes/i386-dis.c')
-rw-r--r--opcodes/i386-dis.c24
1 files changed, 20 insertions, 4 deletions
diff --git a/opcodes/i386-dis.c b/opcodes/i386-dis.c
index d48e6de..d3acb84 100644
--- a/opcodes/i386-dis.c
+++ b/opcodes/i386-dis.c
@@ -4374,16 +4374,32 @@ PNI_Fixup (int extrachar ATTRIBUTE_UNUSED, int sizeflag)
{
/* mwait %eax,%ecx */
strcpy (p, "mwait");
+ if (!intel_syntax)
+ strcpy (op1out, names32[0]);
}
else
{
/* monitor %eax,%ecx,%edx" */
strcpy (p, "monitor");
- strcpy (op3out, names32[2]);
+ if (!intel_syntax)
+ {
+ if (!mode_64bit)
+ strcpy (op1out, names32[0]);
+ else if (!(prefixes & PREFIX_ADDR))
+ strcpy (op1out, names64[0]);
+ else
+ {
+ strcpy (op1out, names32[0]);
+ used_prefixes |= PREFIX_ADDR;
+ }
+ strcpy (op3out, names32[2]);
+ }
+ }
+ if (!intel_syntax)
+ {
+ strcpy (op2out, names32[1]);
+ two_source_ops = 1;
}
- strcpy (op1out, names32[0]);
- strcpy (op2out, names32[1]);
- two_source_ops = 1;
codep++;
}