Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Andrew Cagney <cagney@gnu.org>
To: Sherry Samuel <SherryS@KPITCummins.com>
Cc: gdb-patches@sources.redhat.com
Subject: Re: Porting h8300 - gdb frame to new frame code
Date: Fri, 03 Sep 2004 20:49:00 -0000	[thread overview]
Message-ID: <4138D88A.3080902@gnu.org> (raw)
In-Reply-To: <4A1BE23A7B777442B60F4B4916AE0F130292EAE4@sohm.kpit.com>


> I have introduced the new frame related functions as shown in the patch below.
> 
> Also the following function has been modified:
>    h8300_examine_prologue
> 
> But while executing the command "info f" I am getting wrong location of args and locals 
> (i.e. it is giving the location as the location of sp, where as is it should be the location 
> of frame). I have changed only the "get_frame_base " argument in "h8300_examine_prologue" to 
> the cache->base as it would be the location of stack address. 

There are two ``frame base''s.  The ``id.stack_addr'' used by 
frame-unwind and the stack variables base address.

For Dwarf2 it is Call Frame Information's Call Frame Address, and 
DDW_AT_frame_base.

For a traditional frame unwinder it's typically the previous frame's 
top-of-stack, and the [virtual] frame pointer (typically the fp register).

What's going wrong depends on which of the two is being used, however:

- for tradtional frames the base is often simply wrong

- dwarf2-frame doesn't compute the variables base address correctly, it 
isn't a major problem as the other dwarf2 code doesn't use it :-(

> Is it due to the fact that the generated dwarf 2 information for H8300 is not correct?

Andrew



      reply	other threads:[~2004-09-03 20:49 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-09-01  4:56 Sherry Samuel
2004-09-03 20:49 ` Andrew Cagney [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=4138D88A.3080902@gnu.org \
    --to=cagney@gnu.org \
    --cc=SherryS@KPITCummins.com \
    --cc=gdb-patches@sources.redhat.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