From: Fernando Nasser <fnasser@redhat.com>
To: Andrew Cagney <ac131313@cygnus.com>
Cc: Michael Snyder <msnyder@cygnus.com>,
Fernando Nasser <fnasser@cygnus.com>,
Daniel Jacobowitz <dmj+@andrew.cmu.edu>,
gdb-patches@sourceware.cygnus.com
Subject: Re: [RFA] Testsuite addition for x86 linux GDB and SIGALRM fix
Date: Thu, 26 Jul 2001 07:14:00 -0000 [thread overview]
Message-ID: <3B60251A.E9726676@redhat.com> (raw)
In-Reply-To: <3B5F7700.6030407@cygnus.com>
Andrew Cagney wrote:
>
> > Michael Snyder wrote:
> >
> >>
> >> I must disagree. Often, when you reach this line and you
> >> want to step into foo, you will not notice the call to bar
> >> until it is too late and you have stepped into bar.
> >>
> >> When that happens, the only way to reach foo is to "finish" from
> >> bar, and then step again.
> >>
> >
> >
> > As I have explained in this thread (one month ago), the single stepping
> > caused by finish would stop as soon as foo is entered -- exactly the
> > behavior you want.
>
> I think that would be very counter intuitive. The primatives are:
>
> o step executes instructions until you
> leave the current line
> (be it enter a function or reach a new
> line)
>
'step' should never leave you in the same line from where you've issued
it. That is counter intuitive, even if you had a stop-finish in the
middle.
> o finish leaves the current function
> (reducing the stack depth by one)
Exactly. We are talking about a source line with 'foo (bar ())' on it.
The problem (as I said one month ago) is that we do not have a "finishi'
which could perfectly leave the program at the return point, without
concerns of return value handling, source line numbers etc. But
"finish" is a source level command and source level commands should not
leave you in the middle of source lines.
Once finished the call it was in it should either:
1) stop at the beginning of the next source level instruction -- the one
after the call (remember, it is a source level command)
2) stop after the prolog of a subroutine if there is another call in the
same originating upper level source line.
When the user issues a "step" on 'foo (bar ())' source line, he/she may
want to enter either bar() or foo(). We cannot know that, so we must
stop at each one and he/she can go to the next by issuing "finish",
i.e., "finish _this_ subroutine". When he/she doesn't want to stop
anymore (i.e., bar() was the one they were interested into), a "next"
can be used.
--
Fernando Nasser
Red Hat Canada Ltd. E-Mail: fnasser@redhat.com
2323 Yonge Street, Suite #300
Toronto, Ontario M4P 2C9
next prev parent reply other threads:[~2001-07-26 7:14 UTC|newest]
Thread overview: 27+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <200005192321.e4JNLEv13368@delius.kettenis.local>
2001-06-27 22:22 ` Andrew Cagney
2001-06-28 10:54 ` Michael Snyder
2001-07-09 14:21 ` Fernando Nasser
2001-07-09 14:34 ` Daniel Jacobowitz
[not found] ` <3B4A2C7C.85C688C4@cygnus.com>
2001-07-09 15:17 ` Daniel Jacobowitz
2001-07-09 15:28 ` Fernando Nasser
2001-07-25 16:11 ` Michael Snyder
2001-07-25 16:45 ` Fernando Nasser
2001-07-25 18:48 ` Andrew Cagney
2001-07-26 7:14 ` Fernando Nasser [this message]
2001-07-26 7:44 ` Eli Zaretskii
2001-07-26 7:51 ` Eli Zaretskii
2001-07-26 8:18 ` Eli Zaretskii
2001-07-26 8:48 ` Fernando Nasser
2001-07-26 8:56 ` Eli Zaretskii
2001-07-26 10:21 ` Fernando Nasser
2001-07-26 10:38 ` Fernando Nasser
2001-07-26 10:06 ` Andrew Cagney
2001-07-26 10:24 ` Fernando Nasser
2001-07-26 10:45 ` Andrew Cagney
2001-07-26 10:54 ` Fernando Nasser
2001-07-26 6:10 ` Michael Snyder
2001-07-26 7:14 ` Fernando Nasser
2001-07-26 7:45 ` Michael Snyder
2001-07-26 7:51 ` Fernando Nasser
[not found] <200106281927.MAA29407@stanley.cygnus.com>
2001-06-28 12:41 ` Stan Shebs
2001-06-28 13:02 Michael Elizabeth Chastain
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=3B60251A.E9726676@redhat.com \
--to=fnasser@redhat.com \
--cc=ac131313@cygnus.com \
--cc=dmj+@andrew.cmu.edu \
--cc=fnasser@cygnus.com \
--cc=gdb-patches@sourceware.cygnus.com \
--cc=msnyder@cygnus.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