Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Andrew Cagney <ac131313@redhat.com>
To: Mark Kettenis <kettenis@chello.nl>
Cc: gdb-patches@sources.redhat.com, brobecker@act-europe.fr, mludvig@suse.cz
Subject: Re: [i386newframe] New branch
Date: Sat, 08 Mar 2003 16:11:00 -0000	[thread overview]
Message-ID: <3E6A1618.5000104@redhat.com> (raw)
In-Reply-To: <200303081233.h28CXiex040572@elgar.kettenis.dyndns.org>

> Per Andrews suggestion, I just created a new branch, and checked in
> the attached on it.  This stuff works for me on
> i386-unknown-freebsd4.7.  Interix and x86-64 are almost certainly
> broken on the branch.  Let's fix those targets and merge this into
> mainline when Andrew is finished diddling with the interfaces :-).

s/diddling/deleting/

> +{
> +  /* FIXME: kettenis/20030302: I don't understand why the cache isn't
> +     already initialized.  */
> +  struct i386_frame_cache *cache = i386_frame_cache (frame, cachep);
> +

On the branch, while the frame code notionally uses the sequence:

	pc = frame_pc_unwind(next);
	id = frame_id_unwind(next);

it expands to:

prev->pc = next->unwind->prev_register (next->next, 
&next->prologue_cache, PC_REGNUM);
prev->id = prev->unwind->this_id (next, &prev->prologue_cache);

So while the PC is unwound first, it is the ID unwind call that is first 
to see prev's uninitialized prologue cache.

Thinking about it, the new frame's PC can be determined solely from 
unwound register values.  For the ID, however, the prev's frame's 
prologue first needs to be examined to determine, for instance, which 
register from the next frame needs to be unwound.

(the mainline doesn't do this).

Andrew



  reply	other threads:[~2003-03-08 16:11 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-03-08 12:33 Mark Kettenis
2003-03-08 16:11 ` Andrew Cagney [this message]
  -- strict thread matches above, loose matches on Subject: below --
2003-03-08 12:32 Mark Kettenis

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=3E6A1618.5000104@redhat.com \
    --to=ac131313@redhat.com \
    --cc=brobecker@act-europe.fr \
    --cc=gdb-patches@sources.redhat.com \
    --cc=kettenis@chello.nl \
    --cc=mludvig@suse.cz \
    /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