Mirror of the gdb mailing list
 help / color / mirror / Atom feed
From: Jan Kratochvil <jan.kratochvil@redhat.com>
To: Eli Zaretskii <eliz@gnu.org>
Cc: gdb@sourceware.org
Subject: Re: GDB and -gdwarf-5
Date: Thu, 07 Sep 2017 19:24:00 -0000	[thread overview]
Message-ID: <20170907192447.GA25323@host1.jankratochvil.net> (raw)
In-Reply-To: <83inguz5cz.fsf@gnu.org>

On Thu, 07 Sep 2017 21:16:44 +0200, Eli Zaretskii wrote:
> I have GCC 6.3.0 installed, and it seems to support DWARF2 version 5
> via the -gdwarf-5 switch.  But I wanted to make sure I really get that
> version of debug info, so I tried "info source" in GDB.  But that
> command doesn't tell the version of DWARF2.  Is there a GDB command
> which does?
> 
> I also tried "objdump --dwarf=info" (Binutils 2.29), but that says the
> DWARF2 version is 4.  So now I'm confused.

Here gcc-6.3.1-1.fc25.x86_64 really accepts -gdwarf-5 but still it does produce
only DWARF 4.  I do not know why.

gcc-7.1.1-3.fc26.x86_64 does produce DWARF 5.

You should really see from objdump/readelf:
  Compilation Unit @ offset 0x0:
   Length:        0x13c (32-bit)
   Version:       5


Jan


  reply	other threads:[~2017-09-07 19:24 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-09-07 19:16 Eli Zaretskii
2017-09-07 19:24 ` Jan Kratochvil [this message]
2017-09-07 20:16   ` Eli Zaretskii
2017-09-07 19:28 ` Joel Brobecker
2017-09-07 20:18   ` Eli Zaretskii

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20170907192447.GA25323@host1.jankratochvil.net \
    --to=jan.kratochvil@redhat.com \
    --cc=eliz@gnu.org \
    --cc=gdb@sourceware.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox