Re: [PATCH v2 4/4] arc: Add arc-*-linux regformats

Shahab Vahedi
2020-06-15T23:37:50Z

On Thu, May 14, 2020 at 11:12:55AM -0400, Simon Marchi wrote:
> On 2020-04-28 12:04 p.m., Shahab Vahedi via Gdb-patches wrote:
> > From: Anton Kolesov <Anton.Kolesov@synopsys.com>
> >
> > gdb/ChangeLog:
> > 2020-04-28 Anton Kolesov <anton.kolesov@synopsys.com>
> >
> > * features/Makefile: Add new files and expedite registers.
> > * regformats/arc-arcompact-Linux.dat: New file.
> > * regformats/arc-v2-Linux.dat: Likewise.
>
> Can you explain why this is useful? I always forget, but I have the feeling
> that regformats are something we are going away from, and that if you support
> target descriptions, you don't need that... but I would need to refresh my
> memory.

To my understanding, the values of "expedite" registers are always transferred
from the "server" to GDB client. With every step you take, or any stop you do,
GDB client will know about the value of "expedite" registers. In case of ARC,
those are the "program counter" and "stack pointer" registers.
I _think_ the "dat" files are the mechanism holding information about that.
After all it is generated from the XML and we also followed other targets
in doing so.

Shahab