From: Daniel Jacobowitz Date: Wed, 15 Mar 2006 16:59:54 +0000 (+0000) Subject: * mips-tdep.c (mips_gdbarch_init): Default 64-bit ELF files to N64. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=26c53e508c3991ad163ac1eb181ff8cbe86fd921;p=binutils-gdb.git * mips-tdep.c (mips_gdbarch_init): Default 64-bit ELF files to N64. --- diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 41aeb00546d..db6d6be3a80 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,7 @@ +2006-03-15 Daniel Jacobowitz + + * mips-tdep.c (mips_gdbarch_init): Default 64-bit ELF files to N64. + 2006-03-15 Daniel Jacobowitz * mips-tdep.c (is_mips16_addr, mips32_next_pc, add_offset_16): diff --git a/gdb/mips-tdep.c b/gdb/mips-tdep.c index 8ea209f05b0..880dfcc3494 100644 --- a/gdb/mips-tdep.c +++ b/gdb/mips-tdep.c @@ -4764,6 +4764,13 @@ mips_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches) } } + /* Default 64-bit objects to N64 instead of O32. */ + if (found_abi == MIPS_ABI_UNKNOWN + && info.abfd != NULL + && bfd_get_flavour (info.abfd) == bfd_target_elf_flavour + && elf_elfheader (info.abfd)->e_ident[EI_CLASS] == ELFCLASS64) + found_abi = MIPS_ABI_N64; + if (gdbarch_debug) fprintf_unfiltered (gdb_stdlog, "mips_gdbarch_init: found_abi = %d\n", found_abi);