Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Michael Snyder <msnyder@redhat.com>
To: Jim Ingham <jingham@apple.com>
Cc: gdb-patches@sources.redhat.com
Subject: Re: [RFC] breakpoints and function prologues...
Date: Fri, 23 Aug 2002 11:45:00 -0000	[thread overview]
Message-ID: <3D668026.5758C700@redhat.com> (raw)
In-Reply-To: <FBF1C73E-B6BD-11D6-AFAD-00039379E320@apple.com>

Jim Ingham wrote:
> 
> On Thursday, August 22, 2002, at 04:34  PM,
> gdb-patches-digest-help@sources.redhat.com wrote:
> 
> >> The question is, is there a strong reason to change a behavior
> >> that has been consistent for a very long time (even if undocumented).
> >> Even if the ability to debug the prologue is un-important for most
> >> users, it is important to some, and those users (GCC developers,
> >> for instance) may be quite accustomed to the current behavior.
> >> I am, for instance...
> 
> The varobj code will fail with file:line number breakpoint setting on
> the { that starts the function.  This is, of course, not a problem for
> command-line gdb users, but varobj IS a part of gdb...  Until we have
> the CFI stuff well enough set up that, on landing at the beginning of
> the prologue, the scanner will tell us where the stack frame WILL be
> when it has been set up so we can record this properly, this will be a
> problem.

Mmmm, sorry, but writing a new bit that conflicts with an old bit
doesn't necessarily make the old bit wrong.  There's usually another
way to implement the new bit.


> > Incidentally, it would make the new behavior more in line with the
> > behavior seen when breaking by function name. If later we decide to
> > change the "break funcname" to stop skipping prologues because GDB now
> > has all the machinery that makes the skipping unnecessary, I would
> > likewise argue that we should change back the behavior of "break
> > linenum" as well.
> >
> 
> The patch I sent you makes prologue skipping for file:line breakpoints
> hang off the same flag - "funfirstline" - that the function name ones
> use.  So if we decide to back it out, we just change the value we pass
> to decode_line_1, and you are done...

But I'm not convinced that the file:line behavior was meant to
behave the same as the func_name behavior.  To me, associating 
the prologue code with the open curly brace seems natural.
You have to associate it with SOME line (or else make an even
more special case out of it).  Haveing a way to specify it by
line seems better than not having a way.  Likewise, it seems 
practical to me that the epilogue code is associated with the
close-curly brace.  That way there is a place to set a breakpoint
after the function is finished but before it returns.


  parent reply	other threads:[~2002-08-23 18:34 UTC|newest]

Thread overview: 36+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <1030059293.13128.ezmlm@sources.redhat.com>
2002-08-23 10:50 ` Jim Ingham
2002-08-23 11:34   ` Andrew Cagney
2002-08-24 18:31     ` Jim Ingham
2002-08-25  7:45       ` Andrew Cagney
2002-08-25  8:21         ` Daniel Jacobowitz
2002-08-25 15:24         ` Jim Ingham
2002-08-23 11:45   ` Michael Snyder [this message]
2002-08-23 11:48     ` Daniel Jacobowitz
     [not found] <1029446396.15888.ezmlm@sources.redhat.com>
2002-08-15 15:26 ` Jim Ingham
2002-08-15 18:05   ` Andrew Cagney
2002-08-15 19:11     ` Joel Brobecker
2002-08-16 10:02       ` Jim Blandy
2002-08-16 10:17         ` Joel Brobecker
2002-08-15 19:18     ` Daniel Jacobowitz
2002-08-16  9:34     ` Jim Blandy
2002-08-16 11:34     ` Jim Ingham
2002-08-22 15:38     ` Michael Snyder
2002-08-22 15:56       ` Andrew Cagney
2002-08-22 16:34         ` Michael Snyder
     [not found] <1028439120.16228.ezmlm@sources.redhat.com>
2002-08-06 13:37 ` Jim Ingham
2002-08-14 22:57   ` Andrew Cagney
2002-08-15  6:53     ` Daniel Jacobowitz
2002-08-22 15:33       ` Michael Snyder
2002-08-22 16:19         ` Joel Brobecker
2002-08-23 11:27         ` Daniel Jacobowitz
     [not found] <1027384602.26926.ezmlm@sources.redhat.com>
2002-07-22 18:54 ` Jim Ingham
2002-07-22 22:49   ` Joel Brobecker
2002-07-22 17:36 Joel Brobecker
2002-07-23 16:53 ` Jim Blandy
2002-07-26  6:12   ` Joel Brobecker
2002-07-29 13:34     ` Daniel Jacobowitz
2002-07-29 23:57     ` Jim Blandy
2002-07-30 20:18       ` Joel Brobecker
2002-07-31 13:55         ` Jim Blandy
2002-08-01 15:44           ` Michael Snyder
2002-08-02 23:48             ` Jim Blandy

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=3D668026.5758C700@redhat.com \
    --to=msnyder@redhat.com \
    --cc=gdb-patches@sources.redhat.com \
    --cc=jingham@apple.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