From owner-svn-src-all@FreeBSD.ORG Mon Mar 19 03:27:09 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 965701065675; Mon, 19 Mar 2012 03:27:09 +0000 (UTC) (envelope-from gonzo@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 827DD8FC14; Mon, 19 Mar 2012 03:27:09 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q2J3R9tr049099; Mon, 19 Mar 2012 03:27:09 GMT (envelope-from gonzo@svn.freebsd.org) Received: (from gonzo@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q2J3R9GG049097; Mon, 19 Mar 2012 03:27:09 GMT (envelope-from gonzo@svn.freebsd.org) Message-Id: <201203190327.q2J3R9GG049097@svn.freebsd.org> From: Oleksandr Tymoshenko Date: Mon, 19 Mar 2012 03:27:09 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r233159 - head/contrib/gdb/gdb X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 19 Mar 2012 03:27:09 -0000 Author: gonzo Date: Mon Mar 19 03:27:08 2012 New Revision: 233159 URL: http://svn.freebsd.org/changeset/base/233159 Log: fix ABI detection logic: for 64-bit elf objects set default ABI to n64. Modified: head/contrib/gdb/gdb/mips-tdep.c Modified: head/contrib/gdb/gdb/mips-tdep.c ============================================================================== --- head/contrib/gdb/gdb/mips-tdep.c Mon Mar 19 02:10:40 2012 (r233158) +++ head/contrib/gdb/gdb/mips-tdep.c Mon Mar 19 03:27:08 2012 (r233159) @@ -5437,6 +5437,13 @@ mips_gdbarch_init (struct gdbarch_info i } } + /* 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);