On Thu, 2020-09-10 at 13:16 +0200, Jakub Jelinek wrote: > On Wed, Sep 09, 2020 at 09:57:54PM +0200, Mark Wielaard wrote: > > --- a/gcc/doc/invoke.texi > > +++ b/gcc/doc/invoke.texi > > @@ -9057,13 +9057,14 @@ possible. > > @opindex gdwarf > > Produce debugging information in DWARF format (if that is supported). > > The value of @var{version} may be either 2, 3, 4 or 5; the default version > > -for most targets is 4. DWARF Version 5 is only experimental. > > +for most targets is 5 (with the exception of vxworks and darwin which > > +default to version 2). > > I think in documentation we should spell these VxWorks and Darwin/Mac OS X
OK. As attached. Are we ready to flip the default to 5? Thanks, Mark
From 409bd1b2c60905b0f96c94fface12154d3be4d32 Mon Sep 17 00:00:00 2001 From: Mark Wielaard <m...@klomp.org> Date: Tue, 29 Sep 2020 15:52:44 +0200 Subject: [PATCH] Default to DWARF5 gcc/ChangeLog: * common.opt (gdwarf-): Init(5). * doc/invoke.texi (-gdwarf): Document default to 5. --- gcc/common.opt | 2 +- gcc/doc/invoke.texi | 7 ++++--- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/gcc/common.opt b/gcc/common.opt index 292c2de694ef..d1722de80bf0 100644 --- a/gcc/common.opt +++ b/gcc/common.opt @@ -3148,7 +3148,7 @@ Common Driver JoinedOrMissing Negative(gdwarf-) Generate debug information in default version of DWARF format. gdwarf- -Common Driver Joined UInteger Var(dwarf_version) Init(4) Negative(gstabs) +Common Driver Joined UInteger Var(dwarf_version) Init(5) Negative(gstabs) Generate debug information in DWARF v2 (or later) format. ggdb diff --git a/gcc/doc/invoke.texi b/gcc/doc/invoke.texi index 2091e0cd23b9..e6453374bcd4 100644 --- a/gcc/doc/invoke.texi +++ b/gcc/doc/invoke.texi @@ -9210,14 +9210,15 @@ possible. @itemx -gdwarf-@var{version} @opindex gdwarf Produce debugging information in DWARF format (if that is supported). -The value of @var{version} may be either 2, 3, 4 or 5; the default version -for most targets is 4. DWARF Version 5 is only experimental. +The value of @var{version} may be either 2, 3, 4 or 5; the default +version for most targets is 5 (with the exception of VxWorks and +Darwin/Mac OS X which default to version 2). Note that with DWARF Version 2, some ports require and always use some non-conflicting DWARF 3 extensions in the unwind tables. Version 4 may require GDB 7.0 and @option{-fvar-tracking-assignments} -for maximum benefit. +for maximum benefit. Version 5 requires GDB 8.0 or higher. GCC no longer supports DWARF Version 1, which is substantially different than Version 2 and later. For historical reasons, some -- 2.18.4