Re: [PATCH 4/8] Remove regcache_descr::nr_raw_registers

Simon Marchi
2017-10-31T14:27:52Z

On 2017-10-27 05:31 AM, Yao Qi wrote:
> struct regcache_descr has fields nr_raw_registers and gdbarch, and
> nr_raw_registers can be got via gdbarch_num_regs (gdbarch), so it looks
> nr_raw_registers is redundant. This patch removes it.

I would suggest adding a num_regs method to regcache to wrap the call to
gdbarch_num_regs, so that if we need to change that call, we have only one
place to change. Otherwise, LGTM.

Simon