This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
c/773: Bugs with -gdwarf options
- To: gcc-gnats at gcc dot gnu dot org
- Subject: c/773: Bugs with -gdwarf options
- From: Joseph Myers <jsm28 at cam dot ac dot uk>
- Date: Sat, 11 Nov 2000 13:52:53 +0000
- Cc: jsm28 at cam dot ac dot uk
>Number: 773
>Category: c
>Synopsis: Bugs with -gdwarf options
>Confidential: no
>Severity: non-critical
>Priority: medium
>Responsible: unassigned
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Sat Nov 11 05:56:00 PST 2000
>Closed-Date:
>Last-Modified:
>Originator: Joseph S. Myers
>Release: 2.97 20001111 (experimental)
>Organization:
none
>Environment:
System: Linux decomino 2.2.17 #1 Mon Sep 4 20:22:16 UTC 2000 i686 unknown
Architecture: i686
host: i686-pc-linux-gnu
build: i686-pc-linux-gnu
target: i686-pc-linux-gnu
>Description:
There are some problems with the various options beginning -gdwarf:
GCC no longer accepts -gdwarf2 meaning DWARF version 1 debug level 2,
presumably to avoid confusion. However, the documentation has not
been updated for this; it still includes
@itemx -gdwarf@var{level}
Error messages from -gdwarf2 are duplicated:
$ gcc -c -gdwarf2 -o /dev/null t.c
cc1: use -gdwarf -g2 for DWARF v1, level 2
cc1: use -gdwarf-2 for DWARF v2
cc1: use -gdwarf -g2 for DWARF v1, level 2
cc1: use -gdwarf-2 for DWARF v2
$
So are those from -gdwarf1:
$ gcc -c -gdwarf1 -o /dev/null t.c
cc1: use -gdwarf -g1 for DWARF v1, level 1
cc1: use -gdwarf -g1 for DWARF v1, level 1
$
Some nonsense usages, such as -gdwarf-17, are not detected:
$ gcc -c -gdwarf-17 -o /dev/null t.c
$
>How-To-Repeat:
See examples above.
>Fix:
Update documentation; ensure that messages are only given once; give
an appropriate error for -gdwarf-17.
>Release-Note:
>Audit-Trail:
>Unformatted: