Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Mark Kettenis <mark.kettenis@xs4all.nl>
To: drow@false.org
Cc: gdb-patches@sourceware.org
Subject: Re: [FYI] Inlining support, rough patch
Date: Thu, 17 Jul 2008 23:53:00 -0000	[thread overview]
Message-ID: <200807172353.m6HNr1nY015884@brahms.sibelius.xs4all.nl> (raw)
In-Reply-To: <20080715192020.GB3094@caradoc.them.org> (message from Daniel 	Jacobowitz on Tue, 15 Jul 2008 15:20:20 -0400)

> Date: Tue, 15 Jul 2008 15:20:20 -0400
> From: Daniel Jacobowitz <drow@false.org>
> 
> I'm looking for any comments on the patch itself, test coverage on
> different systems (of both the patch and its included test cases), and
> for people to try it and tell me whether it works naturally or if any
> of my design choices seem wrong.  I don't know of any bugs in the GDB
> patch, although there are some limitations (see the new manual
> chapter).  Beware, though, it makes GDB more sensitive to incorrect
> debug info from GCC.

OK, I've looked a bit more at this diff, but I don't think I
completely understand it yet.  I really, really, don't like the way
you turn the frame unwinding completely upside down though.  Im afraid
that to me, thist suggests that your approach is seriously flawed.
Another indication is that you seem to need state for the inline
unwinder.

I can see why it would be desirable to have inlined functions appear
in a backtrace.  And I don't necessarily disagree with doing this
through inlined frames.  While they're not real stack frames, they're
not too different from frames we create for leaf calls that don't have
a stack frame of their own.  The important question is what the frame
ID for such a frame should be.  It seems you use the stack address and
entry point of the function in which the code was inlined.  As a
consequence you need to extend the frame ID to distinguish it from
that surrounding frame.  I think the correct thing to do is to use the
code address (low address or entry point) of the inlined function and
perhaps the stack pointer at that point to construct the frame ID.

I think this is doable if the inline unwinder is integrated with the
dwarf2 unwinder, or at least shares code with it.  That way the
generic frame unwinding code can stay much the way it is.  These
frames probably need to be marked and the unwinding code probably
needs a way to skip them.  But that will only have a fairly limited
impact.


  reply	other threads:[~2008-07-17 23:53 UTC|newest]

Thread overview: 38+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-06-13 19:39 Daniel Jacobowitz
2008-06-13 19:43 ` Daniel Jacobowitz
2008-06-23 12:03 ` Jan Kratochvil
2008-06-23 14:23   ` Daniel Jacobowitz
2008-07-02 19:15   ` Daniel Jacobowitz
2008-07-03 11:22     ` [FYI] Inlining support, rough patch [break-by-function-name] Jan Kratochvil
2008-07-03 16:01       ` Daniel Jacobowitz
2008-07-12  7:41         ` Jan Kratochvil
2008-07-08  0:12     ` [FYI] Inlining support, rough patch Daniel Jacobowitz
2008-07-15 19:21 ` Daniel Jacobowitz
2008-07-17 23:53   ` Mark Kettenis [this message]
2008-07-18 13:03     ` Daniel Jacobowitz
     [not found]       ` <200807251446.m6PEkfwc027635@brahms.sibelius.xs4all.nl>
2008-07-25 17:47         ` Daniel Jacobowitz
2009-03-31  3:06           ` Tom Tromey
2009-03-31 20:49             ` Mark Kettenis
2009-03-31 22:13               ` Daniel Jacobowitz
2009-04-20 15:49               ` Daniel Jacobowitz
2009-04-20 15:54                 ` Jan Kratochvil
2009-06-27 18:01                   ` Daniel Jacobowitz
2009-06-28 10:16                     ` Jan Kratochvil
2009-06-28 13:35                       ` Daniel Jacobowitz
2009-06-30 16:11                       ` Tom Tromey
2009-06-30 16:50                         ` Jan Kratochvil
2009-04-22 22:04                 ` Mark Kettenis
2009-04-23  3:17                   ` Eli Zaretskii
2009-04-23  5:56                   ` Stan Shebs
2009-04-23 12:48                   ` Daniel Jacobowitz
2009-06-18 17:55                     ` Tom Tromey
2009-06-20  9:57                       ` Mark Kettenis
2009-06-20 19:28                         ` Samuel Bronson
2009-04-24 21:44                   ` Thiago Jung Bauermann
2008-07-18  2:02   ` Paul Pluzhnikov
2008-07-18  3:07     ` Daniel Jacobowitz
2008-07-20 14:41   ` Eli Zaretskii
2008-07-25 13:54   ` Eli Zaretskii
2008-07-25 14:26     ` Daniel Jacobowitz
2008-07-25 16:11       ` Daniel Jacobowitz
2008-07-26  5:58       ` 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=200807172353.m6HNr1nY015884@brahms.sibelius.xs4all.nl \
    --to=mark.kettenis@xs4all.nl \
    --cc=drow@false.org \
    --cc=gdb-patches@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