This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [rfc]: Replace current_gdbarch in sentinel-frame.c
- From: Thiago Jung Bauermann <bauerman at br dot ibm dot com>
- To: Ulrich Weigand <uweigand at de dot ibm dot com>
- Cc: Markus Deuling <deuling at de dot ibm dot com>, GDB Patches <gdb-patches at sourceware dot org>
- Date: Fri, 15 Feb 2008 16:40:29 -0200
- Subject: Re: [rfc]: Replace current_gdbarch in sentinel-frame.c
- References: <200802151743.m1FHhsnE027334@d12av02.megacenter.de.ibm.com>
On Fri, 2008-02-15 at 18:43 +0100, Ulrich Weigand wrote:
> Markus Deuling wrote:
>
> > @@ -54,7 +54,7 @@ sentinel_frame_prev_register (struct fra
> > onto the corresponding hardware register. */
> > *optimized = 0;
> > *lvalp = lval_register;
> > - *addrp = register_offset_hack (current_gdbarch, regnum);
> > + *addrp = register_offset_hack (get_frame_arch (next_frame), regnum);
> > *realnum = regnum;
>
> This is not OK -- as the sentinel frame is always the innermost
> frame, next_frame will always be NULL here.
Actually, what I observe here when running GDB is that next_frame is the
sentinel frame, probably because sentinel frame's next field points back
to itself.
--
[]'s
Thiago Jung Bauermann
Software Engineer
IBM Linux Technology Center