This is the mail archive of the
gdb@sources.redhat.com
mailing list for the GDB project.
Re: Displaying more than 16 registers with GDB for ARM targets
- From: Andrew Cagney <ac131313 at cygnus dot com>
- To: Craig Hackney <craig at triscend dot com>
- Cc: "'gdb at sources dot redhat dot com'" <gdb at sources dot redhat dot com>
- Date: Sun, 12 May 2002 23:43:12 -0400
- Subject: Re: Displaying more than 16 registers with GDB for ARM targets
- References: <2407239113CD914CBA855A47698F01B062232C@SUGAH2.triscend.com>
> My main issue is that I didn't want to change the
> current ARM arch of GDB, rather I wanted to keep as much
> of it the same as I could but allow it to be extended to
> handle the the extra registers I have.
>
> So it sounds like, I have to hack into the current ARM arch
> to make it support my extra registers, this would mean that
> they would be displayed for all ARM targets. Even if the
> target does not support them.
>
> Or..
>
> Create a completely new architecture that is based 99% on the
> ARM, but has my extra register support.
>
> Am I missing something, or does that about sum it up?
A single GDB executable is capable of handling multiple architectures.
I can think of several ways of extending arm-tdep.c to support the extra
registers. Off hand:
- add a command to ``enable'' the registers
- have that command force an architecture change by calling
gdbarch_update_p().
- this will force a call to arm_gdbarch_init()
- that function is then free to re-layout the register cache the way you
want.
Andrew