From: Andrew Cagney <ac131313@cygnus.com>
To: Kevin Buettner <kevinb@redhat.com>
Cc: gdb@sources.redhat.com
Subject: Re: [rfc] Frame based register cache / frame->unwind
Date: Tue, 16 Apr 2002 10:08:00 -0000 [thread overview]
Message-ID: <3CBC5AAD.1040106@cygnus.com> (raw)
In-Reply-To: <1020416161406.ZM30806@localhost.localdomain>
> On Apr 14, 4:58pm, Andrew Cagney wrote:
>
>
>> I'm not too worried about the apparent 2% overhead per frame create
>> though. With the patch applied, the code ends up maintaining both this
>> new cache and the old ->saved_regs table. Rewriting a target to just
>> use the ->unwind_cache, should, I think, claw back the 2% and then some
>> - less need to go out to the target.
>
>
> I'm puzzled. Assuming you don't have dwarf2cfi or the like, how do you
> avoid maintaining the old ->saved_regs table?
Old code would have ->saved_registers. Newer code could pre-load the
cache instead of ->saved_registers.
The case I considered here was SP where ->saved_registers contains the
value and not the address. Added the function
frame_supply_unwound_register() with that in mind.
The others are ``addresses'' though. The cache would need tinkering for
this to work - capable of recording the ``address'' and/or the value.
The frame_supply_unwound_register() (unused) was a step in that direction.
> Hmm... I see that the unwind cache has an ``addr'' field. Does that
> mean that that the prologue analysis function calls
> frame_supply_unwound_register() to set this field?
Yes, that is what I had in mind. But see above, it needs tinkering.
> What is the ``optimized'' flag (in the frame cache) used for?
Grep for OPTIMIZED, it is used but it probably isn't applicable to
registers. I just cache everything :-)
There should probably be an ``unavailable'' indication instead, I'm not
trying to change that part of the code though. (There is a
register_valid() call that isn't reliable.)
thanks!
Andrew
next prev parent reply other threads:[~2002-04-16 17:08 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-04-14 13:58 Andrew Cagney
2002-04-14 18:48 ` Daniel Jacobowitz
2002-04-16 8:10 ` Andrew Cagney
2002-04-16 9:14 ` Kevin Buettner
2002-04-16 10:08 ` Andrew Cagney [this message]
2002-04-17 10:04 ` Andrew Cagney
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=3CBC5AAD.1040106@cygnus.com \
--to=ac131313@cygnus.com \
--cc=gdb@sources.redhat.com \
--cc=kevinb@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