Re: [RFC] gdb/riscv: Improved register alias name creation

Andrew Burgess
2020-06-09T22:58:39Z

* Tom Tromey <tom@tromey.com> [2020-06-09 14:54:23 -0600]:

> >>>>> "Andrew" == Andrew Burgess <andrew.burgess@embecosm.com> writes:
>
> Andrew> The patch below has had only minimal testing so far, but I'm sharing
> Andrew> it here so it can be discussed while I also get it tested.
>
> Andrew> This changes how the 'csr%d' aliases are created, and adds the
> Andrew> dscratch to dscratch0 alias.
>
> I backed out the reversion here; then I did a new merge; then I applied
> this patch and re-ran our internal test suite.
>
> It still fails -- though it does change the failures I see. Now it
> complains about a different register:
>
> (gdb) call debug.trace (me, "You")
> Could not fetch register "mucounteren"; remote failure reply 'E14'

So I forgot to say, the reason I'm so confused by this is that getting
the 'remote failure reply ...' message indicates that GDB does know
about the register, is correctly asking for it, but the remote is not
providing the register.

I rolled GDB back to commit d8af906814bd69dad694e475288401b1dee6ac3a,
which is just before commit the 'RISC-V: Update CSR to privileged spec
1.11.', so based on your original email I was expecting this to work -
unfortunately I'm still seeing the same error here.

Can you confirm which version of GDB you see this passing with.

Thanks,
Andrew