This is the mail archive of the
gdb-patches@sources.redhat.com
mailing list for the GDB project.
Re: RFA: Recognize 'x' in response to 'p' packet
On Fri, Dec 17, 2004 at 05:35:23PM -0500, Jim Blandy wrote:
> Daniel Jacobowitz <drow@false.org> writes:
> > I know this came up a bit already, but could you elaborate on why you
> > had to silently provide a value of 0? We do have a defined interface
> > for 'currently not available', though we do not use it well. This
> > isn't support for the xx response, just a workaround.
>
> I just missed it. Is this (untested!) what you're looking for?
>
> 2004-12-17 Jim Blandy <jimb@redhat.com>
>
> * remote.c (fetch_register_using_p): Recognize a register value
> starting with 'x' as indicating an unfetchable register.
More or less. Spelling, formatting, and the fallthrough here:
> ! /* If this register is unfetchable, tell the regcache. */
> ! if (buf[0] == 'x')
> ! {
> ! regcache_raw_supply (current_regcache, regnum, NULL);
> ! set_register_cached (regnum, -1);
return <something>;
> }
>
> ! /* Otherwise, parse and supply the value. */
My real question, though, is what you needed this for - and whether
marking the register unavailable fixes it.
--
Daniel Jacobowitz