This is the mail archive of the
gdb@sources.redhat.com
mailing list for the GDB project.
Re: ARM and virtual/raw registers
- From: Andrew Cagney <ac131313 at cygnus dot com>
- To: Richard dot Earnshaw at arm dot com
- Cc: gdb at sources dot redhat dot com
- Date: Mon, 13 May 2002 09:13:23 -0400
- Subject: Re: ARM and virtual/raw registers
- References: <200205131234.NAA27740@cam-mail2.cambridge.arm.com>
>
> OK, I'm trying this general approach. One major failure, unfortunately.
>
> The remote-sim code has:
>
> else if (REGISTER_NAME (regno) != NULL
> && *REGISTER_NAME (regno) != '\0')
> {
> char buf[MAX_REGISTER_RAW_SIZE];
> int nr_bytes;
> if (REGISTER_SIM_REGNO (regno) >= 0)
> nr_bytes = sim_fetch_register (gdbsim_desc,
> REGISTER_SIM_REGNO (regno),
> buf, REGISTER_RAW_SIZE (regno));
> ...
> supply_register (regno, buf);
>
> Which is precisely the opposite of what I want: sim_fetch_register needs
> to fetch the raw (uncooked) registers, which is precisely the set that
> don't have names :-(
>
> REGISTER_SIM_REGNO doesn't help, because we never get to the code for the
> registers I need.
Want it fixed? Next to no targets define the macro so changing the the
behavour - make REGISTER_SIM_REGNO totally responsible for the decision
is straight forward.
(In fact, why didn't I do this before).
Andrew