forked from Imagelibrary/binutils-gdb
Properly decode MODRM byte for 64-bit
64-bit mode doesn't use 16-bit address. We should always check SIB byte for address in 64-bit mode. PR gdb/16304 * i386-tdep.c (i386_record_lea_modrm_addr): Don't use 16-bit address in 64-bit mode.
This commit is contained in:
@@ -1,3 +1,9 @@
|
||||
2013-12-19 H.J. Lu <hongjiu.lu@intel.com>
|
||||
|
||||
PR gdb/16304
|
||||
* i386-tdep.c (i386_record_lea_modrm_addr): Don't use 16-bit
|
||||
address in 64-bit mode.
|
||||
|
||||
2013-12-19 H.J. Lu <hongjiu.lu@intel.com>
|
||||
|
||||
PR gdb/16304
|
||||
|
||||
@@ -4209,9 +4209,9 @@ i386_record_lea_modrm_addr (struct i386_record_s *irp, uint64_t *addr)
|
||||
ULONGEST offset64;
|
||||
|
||||
*addr = 0;
|
||||
if (irp->aflag)
|
||||
if (irp->aflag || irp->regmap[X86_RECORD_R8_REGNUM])
|
||||
{
|
||||
/* 32 bits */
|
||||
/* 32/64 bits */
|
||||
int havesib = 0;
|
||||
uint8_t scale = 0;
|
||||
uint8_t byte;
|
||||
|
||||
Reference in New Issue
Block a user