This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Make x86-elf use DWARF-2 not stabs


i?86-elf and x86_64-elf targets default to stabs debugging format.
This default dates back to when x86-elf support was added in
<http://gcc.gnu.org/ml/gcc-patches/1999-07n/msg00254.html> - and given
the copyright dates in the original submission, the support was pretty
old even then.  Even if this default made sense then, deviating from
the usual DWARF-2 used on ELF targets certainly doesn't make sense
now.  As I explained in
<http://gcc.gnu.org/ml/gcc-patches/2011-05/msg01779.html> the
configuration of supported and default debug formats is generally
rather a mess and could probably do with being simplified, but I think
this simple local fix, removing the old PREFERRED_DEBUGGING_TYPE
definition, is appropriate for now for these targets (and in any case
it makes sense to separate semantic changes to what the defaults are
from any changes to how those defaults are implemented).

This patch removes PREFERRED_DEBUGGING_TYPE from
config/i386/i386elf.h, so changing the default to the normal ELF
default of DWARF-2.  This header is also used on i[34567]86-*-rtems*
so it's possible those targets will be affected as well.  I'm not set
up for full testing of x86-elf with FSF sources, but did a sanity
check on this patch by building cc1 and xgcc for i686-elf.  OK to
commit?

2011-11-15  Joseph Myers  <joseph@codesourcery.com>

	* config/i386/i386elf.h (PREFERRED_DEBUGGING_TYPE): Remove.

Index: gcc/config/i386/i386elf.h
===================================================================
--- gcc/config/i386/i386elf.h	(revision 181400)
+++ gcc/config/i386/i386elf.h	(working copy)
@@ -20,10 +20,6 @@
 along with GCC; see the file COPYING3.  If not see
 <http://www.gnu.org/licenses/>.  */
 
-/* Use stabs instead of DWARF debug format.  */
-#undef  PREFERRED_DEBUGGING_TYPE
-#define PREFERRED_DEBUGGING_TYPE DBX_DEBUG
-
 /* The ELF ABI for the i386 says that records and unions are returned
    in memory.  */
 

-- 
Joseph S. Myers
joseph@codesourcery.com


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]