aboutsummaryrefslogtreecommitdiff
path: root/opcodes/i386-dis.c
diff options
context:
space:
mode:
authorH.J. Lu <hjl.tools@gmail.com>2016-10-18 09:06:27 -0700
committerH.J. Lu <hjl.tools@gmail.com>2016-10-18 09:06:27 -0700
commit285963233bc7509edb07c035426ee0096650b0af (patch)
tree3995c2c12d898f768b12d8b6e1dcd91eeb3eb0a3 /opcodes/i386-dis.c
parentda8d7d665521e5b3f67f87341400441a5d0643d5 (diff)
downloadgdb-285963233bc7509edb07c035426ee0096650b0af.zip
gdb-285963233bc7509edb07c035426ee0096650b0af.tar.gz
gdb-285963233bc7509edb07c035426ee0096650b0af.tar.bz2
Check addr32flag instead of sizeflag for rip/eip
Since the address size prefix, 0x67, is ignored for MPX instructions in 64-bit mode, we should check addr32flag instead of sizeflag for rip/eip. PR binutis/20699 * i386-dis.c (OP_E_memory): Check addr32flag instead of sizeflag for rip/eip.
Diffstat (limited to 'opcodes/i386-dis.c')
-rw-r--r--opcodes/i386-dis.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/opcodes/i386-dis.c b/opcodes/i386-dis.c
index cd1321f..4624a6a 100644
--- a/opcodes/i386-dis.c
+++ b/opcodes/i386-dis.c
@@ -15523,7 +15523,7 @@ OP_E_memory (int bytemode, int sizeflag)
if (riprel)
{
set_op (disp, 1);
- oappend (sizeflag & AFLAG ? "(%rip)" : "(%eip)");
+ oappend (!addr32flag ? "(%rip)" : "(%eip)");
}
}
@@ -15538,7 +15538,7 @@ OP_E_memory (int bytemode, int sizeflag)
if (intel_syntax && riprel)
{
set_op (disp, 1);
- oappend (sizeflag & AFLAG ? "rip" : "eip");
+ oappend (!addr32flag ? "rip" : "eip");
}
*obufp = '\0';
if (havebase)