This is the mail archive of the
gdb-patches@sources.redhat.com
mailing list for the GDB project.
Re: [RFA] Tweak in skip_prologue for rs6000
- From: Kevin Buettner <kevinb at redhat dot com>
- To: "Michael Snyder" <michsnyd at cisco dot com>
- Cc: gdb-patches at sources dot redhat dot com
- Date: Thu, 11 Nov 2004 10:04:04 -0700
- Subject: Re: [RFA] Tweak in skip_prologue for rs6000
- Organization: Red Hat
- References: <00c901c4c78b$5e1591f0$5ca56b80@msnyder8600>
On Wed, 10 Nov 2004 17:11:21 -0800
"Michael Snyder" <michsnyd@cisco.com> wrote:
> If I'm right, this will prevent saving lr_offset twice. It looks like the
> existing code intends to invalidate lr_reg, but setting it to zero is not
> an invalid value.
Yes, I agree with your analysis. Setting lr_reg to 0 will cause a
match whenever doing a st[dw]{,u} r0, NUM(r1). While this is okay
if the zero value comes from the mflr case, it is definitely not okay
in the lr_reg invalidation code.
> Probably the same is true for cr_reg and cr_offset...
Yes, it appears so. Would you mind making the same fix for these?
Consider such a patch to be preapproved.
> * rs6000-tdep.c (skip_prologue): After saving lr_offset,
> must invalidate lr_reg (so we don't try to save it again).
Definitely okay.
Thanks for fixing this,
Kevin