Mirror of the gdb mailing list
 help / color / mirror / Atom feed
From: Daniel Jacobowitz <drow@false.org>
To: Alex Bennee <kernel-hacker@bennee.com>
Cc: gdb@sources.redhat.com
Subject: Re: Gcc options for improving debugging?
Date: Wed, 19 Jul 2006 13:31:00 -0000	[thread overview]
Message-ID: <20060719130547.GA18159@nevyn.them.org> (raw)
In-Reply-To: <1153308778.9831.49.camel@okra.transitives.com>

On Wed, Jul 19, 2006 at 12:32:58PM +0100, Alex Bennee wrote:
> An alternate approach is to compile with -O3 but turn off specific
> optimisations which make life tricky for gdb. So far I have:
> 
> * -ggdb3  (obviously)

This doesn't really give you anything beyond -g.  The only difference
is that it will allow you to expand macros, and make your object files
huge.

> * -fno-omit-frame-pointer (seems to help with finding some variables)
> 
> What else would you suggest? Would this be worth adding to section 4.1
> of the manual "Compiling for debugging".

Beyond this there's not really much you can do.  If you need inlining,
you're in trouble, because GDB does not (yet) have decent inlining
support - but it's on the list of things to improve.

-- 
Daniel Jacobowitz
CodeSourcery


  reply	other threads:[~2006-07-19 13:05 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-07-19 13:05 Alex Bennee
2006-07-19 13:31 ` Daniel Jacobowitz [this message]
2006-07-19 17:50   ` Alex Bennee
2006-07-19 17:53     ` Paul Koning
2006-07-20 15:21       ` Daniel Jacobowitz
2006-07-19 17:33 ` Paul Koning
2006-07-20 16:11 ` Frank Ch. Eigler

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=20060719130547.GA18159@nevyn.them.org \
    --to=drow@false.org \
    --cc=gdb@sources.redhat.com \
    --cc=kernel-hacker@bennee.com \
    /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