Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Hui Zhu <teawater@gmail.com>
To: Michael Snyder <msnyder@vmware.com>,
	Pedro Alves <pedro@codesourcery.com>,
	 	"gdb-patches@sourceware.org" <gdb-patches@sourceware.org>,
	Daniel Jacobowitz <drow@false.org>
Subject: Re: [RFA] Patch to fix reverse return from subroutine error
Date: Mon, 29 Jun 2009 00:38:00 -0000	[thread overview]
Message-ID: <daef60380906281738u37f7f0e4scf62e62c9f7b2907@mail.gmail.com> (raw)
In-Reply-To: <20090628210852.GA26015@caradoc.them.org>

Sorry for late everybody.
Looks like we still have trouble with it,right?

We have plan B  for this issue.  This is a old implement when p record
still have reverse command inside it.

This issue is because we don't know the frame_info of step_frame_id.
Without it, we cannot get the frame_info of high level function with
function get_prev_frame.
Without frame_info, we cannot get the frame_id.
Then we cannot make sure if this inferior return from subroutine.

So we can save this prev_frame_id when we save step_frame_id in reverse mode.
in step_once,
      frame = get_current_frame ();
      tp->step_frame_id = get_frame_id (frame);
Update it to inferior_status.
And update it in handle_inferior_event:
  ecs->event_thread->step_range_start = stop_pc_sal.pc;
  ecs->event_thread->step_range_end = stop_pc_sal.end;
  ecs->event_thread->step_frame_id = get_frame_id (frame);
  ecs->event_thread->current_line = stop_pc_sal.line;
  ecs->event_thread->current_symtab = stop_pc_sal.symtab;

Then, we can use it to make sure if inferior return from subroutine or not.

What do you think about it?


Thanks,
Hui



On Mon, Jun 29, 2009 at 05:08, Daniel Jacobowitz<drow@false.org> wrote:
> On Sun, Jun 28, 2009 at 11:44:37AM -0700, Michael Snyder wrote:
>> Great, I looked up your paper, and found it helpful.
>> Are your gdb patches available online?  Any head start
>> would be a boon...
>
> I think I've posted them before, but I can't remember where.  A copy
> is attached.  The epilogue bits are in patch-4.
>
> --
> Daniel Jacobowitz
> CodeSourcery
>


      reply	other threads:[~2009-06-29  0:38 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-06-11  8:27 Hui Zhu
2009-06-27 18:59 ` Michael Snyder
2009-06-27 19:48   ` Pedro Alves
2009-06-27 19:56     ` Daniel Jacobowitz
2009-06-27 20:59     ` Michael Snyder
2009-06-27 21:12       ` Daniel Jacobowitz
2009-06-28 18:46         ` Michael Snyder
2009-06-28 21:09           ` Daniel Jacobowitz
2009-06-29  0:38             ` Hui Zhu [this message]

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=daef60380906281738u37f7f0e4scf62e62c9f7b2907@mail.gmail.com \
    --to=teawater@gmail.com \
    --cc=drow@false.org \
    --cc=gdb-patches@sourceware.org \
    --cc=msnyder@vmware.com \
    --cc=pedro@codesourcery.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