This is the mail archive of the
gdb@sourceware.org
mailing list for the GDB project.
Re: 'g/G' GDB commands
- From: Mark Kettenis <mark dot kettenis at xs4all dot nl>
- To: guillaume dot menant at geensys dot com
- Cc: gdb at sourceware dot org
- Date: Thu, 17 Jan 2008 11:17:20 +0100 (CET)
- Subject: Re: 'g/G' GDB commands
- References: <473C1753.1090409@geensys.com> <20071115133842.GB19518@caradoc.them.org> <14437056.post@talk.nabble.com> <14914940.post@talk.nabble.com>
> Date: Thu, 17 Jan 2008 01:18:51 -0800 (PST)
> From: Guillaume MENANT <guillaume.menant@geensys.com>
>
> I've implemented the reply to the 'g' command but GDB sends me a nack ('-')
> each time (3 times and then freeze).
>
> I'm working on a Atmel AT697E (Sparc V8) in which all registers printed with
> "maint print registers" command exists except csr and dx registers (last
> registers listed below). So I tried to send only supported registers (GDB
> sends nack) and also tried to add '0' padding in order to fill the
> non-implemented registers (same response).
I'm not an expert on GDB's remote protocol, but here is some SPARC
wisdom that might help you.
The %dN registers are pseudo-registers (combining two single-precision
%fN registers into a double-precision value), and should *not* be sent
accross the line.
The %csr register is indeed an implementation defined register (but a
real one). We could define a special LEON2 subtarget in GDB, which
doesn't have this register, but I think it would be easier if you just
passed '0' for this one, since that would avoid all sorts of nasty
configuration issues.
Cheers,
Mark