This is the mail archive of the gdb-patches@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [RFA] Tweak in skip_prologue for rs6000


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


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]