Re: [PATCH v3 2/3] arc: Add hardware loop detection

Simon Marchi
2020-07-15T02:55:34Z

On 2020-07-13 11:45 a.m., Shahab Vahedi wrote:
> From: Shahab Vahedi <shahab@synopsys.com>
>
> For ARC there are registers that are not part of a required set in XML
> target descriptions by default, but are almost always present on ARC
> targets and are universally exposed by the ptrace interface. Hardware
> loop registers being one of them.
>
> LP_START and LP_END auxiliary registers are hardware loop start and end.
> Formally, they are optional, but it is hard to find an ARC configuration
> that doesn't have them. They are always present in processors that can
> run GNU/Linux. GDB needs to know about those registers to implement
> proper software single stepping, since they affect what instruction
> will be next.
>
> This commit adds the code to check for the existance of "lp_start" and
> "lp_end" in XML target descriptions. If they exist, then the function
> reports that the target supports hardware loops.

This looks good to me.

Simon