This is the mail archive of the
gdb@sourceware.org
mailing list for the GDB project.
Re: Help about RSP command 'p'
- From: Wenbo Yang <wenbo dot yang at simplnano dot com>
- To: Sync ma <sync dot jma at gmail dot com>
- Cc: gdb at sourceware dot org
- Date: Wed, 11 Jul 2007 09:14:59 +0800
- Subject: Re: Help about RSP command 'p'
- References: <1184054482.32608.ezmlm@sourceware.org> <4693565C.3050108@simplnano.com> <dcf6addc0707100315x2220b242gdbe72adf438111d2@mail.gmail.com>
Sync ma wrote:
gdb wonder the value of register 37? there only 32 general purpose
regs in my 4KEc cpu.
I used to read some GDB source code related to MIPS arch(ISA). In some MIPS
archs, Reg.37 means PC register. But I have no idea which arch(target) in
"config.sub" your 4KEC belong to. I think the target dependent file
"mips-tdep.c/h" can give you some clue.
Anyway, there should be some handler function in gdbserver for command
'p', but I have not found in gdb-6.5 yet.
Maybe you can find it in "remote.c". 'p' is not a command, it is a RSP packet.
Someone guide me.( Lots question about remote debugging(debugging with
BDIGDB), eg. 'stepi' makes no stop, I could only return to GDB CLI
with 'CTRL+C', A japanese engineer wrote in another maillist says that
some instruction sets may not support tracing... I found a manual for
U-boot debugging with BDI2000, but it can not be reproduced on my MIPS
processor).
It depends on archs. If GDB (compiled for your target) support SW single
stepping, you can achieve "stepi", or you can implement SW single stepping in
your STUB. I have never used "tracing" related command before, so I don't know
if gdb can. What GDB can do depends on how much RSP packets you implement in
your STUB and how much functions registered to GDB in target dependent files. So
concentrate in what you can do, let others go. It is very hard for remote
debugging achieve the same goal as debugging on host.
Regards,
Wenbo
--
Wenbo Yang
The State Key Lab. of Information Security
Graduate School of CAS, 19A Yuquan Road, Beijing, China
Homepage: http://solrex.cn
SimpLight Nanoelectronics Ltd. 6 Zhichun Road, 10th Floor, Beijing, China
Phone: +86-10-5126-6989 --- Email: wenbo.yang@simplnano.com