This is the mail archive of the
gdb@sources.redhat.com
mailing list for the GDB project.
Change rs6000 ELF targets to use DWARF2 by default in GCC.
- To: gcc-patches at gcc dot gnu dot org
- Subject: Change rs6000 ELF targets to use DWARF2 by default in GCC.
- From: Geoff Keating <geoffk at geoffk dot org>
- Date: Sun, 12 Aug 2001 23:51:57 -0700
- CC: gdb at sources dot redhat dot com
- Reply-to: Geoff Keating <geoffk at redhat dot com>
I understand that while DWARF2 may be bigger, it is also more
complete, and in particular it has a better chance of dealing with the
new optimisations. I would rather better debugging information than
smaller debugging information, and those who disagree can always use
-g1 (or -gstabs for that matter).
Tested on powerpc-eabisim. I didn't test gdb as I can't tell which
failures would be "normal" for dwarf2. I am nonetheless hoping
that gdb's testresults on powerpc will improve because of this patch.
I've actually had this patch in my local tree for about 4 months, but
it's only recently that the automated tester has managed to upgrade
its binutils; there is an essential binutils patch that's required for
GCC's libraries to build on the EABI targets (to support
-mrelocatable).
--
- Geoffrey Keating <geoffk@geoffk.org>
===File ~/patches/cygnus/rs6000-dwarf2debug.patch===========
2001-08-12 Geoffrey Keating <geoffk@redhat.com>
* config/rs6000/sysv4.h (PREFERRED_DEBUGGING_TYPE): Use
DWARF2 instead of stabs by default.
Index: config/rs6000/sysv4.h
===================================================================
RCS file: /cvs/gcc/gcc/gcc/config/rs6000/sysv4.h,v
retrieving revision 1.57
diff -p -u -p -r1.57 sysv4.h
--- sysv4.h 2001/08/12 21:17:43 1.57
+++ sysv4.h 2001/08/13 06:21:34
@@ -868,11 +868,11 @@ do { \
/* This is the end of what might become sysv4.h. */
-/* Allow stabs and dwarf, for now, make stabs the default debugging type,
- not dwarf since G++ doesn't support dwarf. */
+/* Use DWARF 2 debugging information by default. */
#undef PREFERRED_DEBUGGING_TYPE
-#define PREFERRED_DEBUGGING_TYPE DBX_DEBUG
+#define PREFERRED_DEBUGGING_TYPE DWARF2_DEBUG
+/* Historically we have also supported stabs debugging. */
#define DBX_DEBUGGING_INFO
/* If we are referencing a function that is static or is known to be
============================================================