Re: RISC-V: Is it reasonable to extend current target_description for KGDB?

"Maciej W. Rozycki" <[email protected]>
Newsgroups gmane.comp.gdb.devel
Message-ID <alpine.LFD.2.21.1910161412390.2438@redsun52.ssa.fujisawa.hgst.com>
On Tue, 15 Oct 2019, Jim Wilson wrote:

> One possible solution is to add a RISC-V specific command to choose
> the register set used for the default p packet.  That way, if there
> are problems with adding registers to it, people have the option to
> switch back to the old way.  We already have the "set riscv
> use-compressed-breakpoints [auto|on|off]" command.  So we could add a
> similar command to choose the number of registers in the default p
> packet, try changing the default to the full 36 register set, and wait
> to see who complains.  People that complain can be told about the
> command to switch back to the old 32 (33?) register set.

 There's such a generic command already available:

(gdb) set tdesc filename ...

 NB, this has nothing to do with the use of `g'/`G' vs `p'/`P' packets, 
both use the same register indices; for the overlapping part, that is of 
course.  Then no heuristics can cover registers outside the range of the 
`g'/`G' packets of course, an XML description does have to be provided for 
those registers to be recognised.

  Maciej
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.