"Info reg doesn't work"

Jim Blandy jimb@redhat.com
Tue Jun 15 22:42:00 GMT 2004


"Xinan Tang" <xinan@tidalnetworks.net> writes:
>   I am porting gdb (6.1) to a new target. After adding a new target that is
> similar to an existing RISC 32bit architecture, I found out two problems:
> 
>   1. `info register' does not work. For example, if I type in `info reg',
> the content of all registers are showing ZERO except PC no matter how many
> instructions are executed.
> 
>   2. Gdb can start execution from _start but can not enter main.
> 
>   Could someone please point to me which files I should take a look to fix
> this problem? Or is there any FAQ to explain how to add a new target based
> on an existing architecture.

Well, you might try looking at gdb/doc/gdbint.texi, the GDB internals
documentation.  But it sounds to me like your target is having trouble
supplying register values to GDB.

How is GDB communicating with the debuggee?  Via the remote protocol?
Via ptrace?  Something else?



More information about the Gdb mailing list