aboutsummaryrefslogtreecommitdiff
path: root/gcc/doc
diff options
context:
space:
mode:
authorJakub Jelinek <jakub@redhat.com>2020-12-04 10:54:45 +0100
committerJakub Jelinek <jakub@redhat.com>2020-12-04 10:54:45 +0100
commit65312dfc64744405326a9f4c243f1b4c8f21de1b (patch)
treee9c5a9cae5d303385de694fe1b32e1c12a1e9fc0 /gcc/doc
parent485b40a5270cf50a7304a9e5cb8aff96bfa3d901 (diff)
downloadgcc-65312dfc64744405326a9f4c243f1b4c8f21de1b.zip
gcc-65312dfc64744405326a9f4c243f1b4c8f21de1b.tar.gz
gcc-65312dfc64744405326a9f4c243f1b4c8f21de1b.tar.bz2
dwarf: Add -gdwarf{32,64} options
The following patch makes the choice between 32-bit and 64-bit DWARF formats selectable by command line switch, rather than being hardcoded through DWARF_OFFSET_SIZE macro. The options themselves don't turn on debug info themselves, so one needs to use -g -gdwarf64 or similar. 2020-12-04 Jakub Jelinek <jakub@redhat.com> * common.opt (-gdwarf32, -gdwarf64): New options. * config/rs6000/rs6000.c (rs6000_option_override_internal): Default dwarf_offset_size to 8 if not overridden from the command line. * dwarf2out.c: Change all occurrences of DWARF_OFFSET_SIZE to dwarf_offset_size. * doc/invoke.texi (-gdwarf32, -gdwarf64): Document.
Diffstat (limited to 'gcc/doc')
-rw-r--r--gcc/doc/invoke.texi14
1 files changed, 13 insertions, 1 deletions
diff --git a/gcc/doc/invoke.texi b/gcc/doc/invoke.texi
index 38c4d6a..671b297 100644
--- a/gcc/doc/invoke.texi
+++ b/gcc/doc/invoke.texi
@@ -453,7 +453,7 @@ Objective-C and Objective-C++ Dialects}.
-gstabs -gstabs+ -gstrict-dwarf -gno-strict-dwarf @gol
-gas-loc-support -gno-as-loc-support @gol
-gas-locview-support -gno-as-locview-support @gol
--gcolumn-info -gno-column-info @gol
+-gcolumn-info -gno-column-info -gdwarf32 -gdwarf64 @gol
-gstatement-frontiers -gno-statement-frontiers @gol
-gvariable-location-views -gno-variable-location-views @gol
-ginternal-reset-location-views -gno-internal-reset-location-views @gol
@@ -9654,6 +9654,18 @@ information as possible into a separate output file with the extension
debug information. To be useful, this option requires a debugger capable of
reading @file{.dwo} files.
+@item -gdwarf32
+@itemx -gdwarf64
+@opindex gdwarf32
+@opindex gdwarf64
+If DWARF debugging information is enabled, the @option{-gdwarf32} selects
+the 32-bit DWARF format and the @option{-gdwarf64} selects the 64-bit
+DWARF format. The default is target specific, on most targets it is
+@option{-gdwarf32} though. The 32-bit DWARF format is smaller, but
+can't support more than 2GiB of debug information in any of the DWARF
+debug information sections. The 64-bit DWARF format allows larger debug
+information and might not be well supported by all consumers yet.
+
@item -gdescribe-dies
@opindex gdescribe-dies
Add description attributes to some DWARF DIEs that have no name attribute,