This is the mail archive of the mailing list for the GDB project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH v6 1/5] tdesc: handle arbitrary strings in tdesc_register_in_reggroup_p

On Tue, May 02, 2017 at 03:40:20PM +0100, Yao Qi wrote:
> Stafford Horne <> writes:
> > tdesc_register_in_reggroup_p in now able to handle arbitrary
> > groups. This is useful when groups are created while the
> > target descriptor file is received from the remote.
> >
> > This can be the case of a soft core target processor where
> > registers/groups can change.
> >
> > gdb/ChangeLog:
> >
> > 2013-02-15  Franck Jullien  <>
> >
> > 	* target-descriptions.c (tdesc_register_in_reggroup_p): Support
> > 	arbitrary strings.
> I am not sure what do you want to change and why do you need this
> change?  I didn't see it in the previous version.
> If you want to control what registers are displayed, you can follow the
> way nds32 used, see nds32-tdep.c:nds32_register_reggroup_p.

Hi Yao,

Thanks for reviewing.  Sorry, this was in previous versions but dropped on
accident then added back, I forgot to mention.

Currenly tdesc_register_in_reggroup_p() only returns true if the register
group number is one of the hard coded reggroups: float, vector, general,
save or restor.

This change is to also allow returning true in the case that the register
group was registered with gdb with reggroup_add().  This seems like
something that will be generally required so it was added to the
target-descriptions definition.  If you think not I can make it for
openrisc only, but I think it makes more sense in tdesc.

This allows the command like, the below to return the registers for the
named reggroup.

  info reg system


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]