Skip to content

Commit d54398a

Browse files
author
Maciej W. Rozycki
committed
MIPS: Respect the "set mips compression" command
This fixes gdbarch matching, making sure one for the opposite compressed ISA variation is not chosen. That in turn makes "set mips compression" work; right now the setting sticks to the initial value, either inferred from the ELF header of the binary first loaded or the default value if no binary has been used. This only affects debugging with no symbol table available or no binary chosen at all, as otherwise symbol annotations determine the compressed ISA variation. * mips-tdep.c (mips_gdbarch_init): Also check the compressed ISA variation in gdbarch matching.
1 parent ab16fce commit d54398a

File tree

2 files changed

+9
-2
lines changed

2 files changed

+9
-2
lines changed

gdb/ChangeLog

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
2014-07-25 Maciej W. Rozycki <[email protected]>
2+
3+
* mips-tdep.c (mips_gdbarch_init): Also check the compressed ISA
4+
variation in gdbarch matching.
5+
16
2014-07-25 Tom Tromey <[email protected]>
27

38
* exec.c (using_exec_ops): Remove.

gdb/mips-tdep.c

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8296,12 +8296,14 @@ mips_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
82968296
arches != NULL;
82978297
arches = gdbarch_list_lookup_by_info (arches->next, &info))
82988298
{
8299-
/* MIPS needs to be pedantic about which ABI the object is
8300-
using. */
8299+
/* MIPS needs to be pedantic about which ABI and the compressed
8300+
ISA variation the object is using. */
83018301
if (gdbarch_tdep (arches->gdbarch)->elf_flags != elf_flags)
83028302
continue;
83038303
if (gdbarch_tdep (arches->gdbarch)->mips_abi != mips_abi)
83048304
continue;
8305+
if (gdbarch_tdep (arches->gdbarch)->mips_isa != mips_isa)
8306+
continue;
83058307
/* Need to be pedantic about which register virtual size is
83068308
used. */
83078309
if (gdbarch_tdep (arches->gdbarch)->mips64_transfers_32bit_regs_p

0 commit comments

Comments
 (0)