This is the mail archive of the gdb@sources.redhat.com 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: Available registers as a target property


> Daniel Jacobowitz wrote:
> ...
> Today, the contents of the register cache and the layout of GDB's regnum
> space are determined by the gdbarch.  There are several hooks for this,
> primarily these three:
>
>        num_regs
>        register_name
>        register_type
>
> The gdbarch determines what raw registers are available.  But this isn't a
> perfect match with what raw registers are _really_ available, because the
> gdbarch only has the clues we use to select a gdbarch available: things like
> byte order and BFD machine number.  At best, those tell us what registers
> the binary we're debugging requires.  The runtime set of registers we can
> see are a property of the target, not of the gdbarch.
> ...

Might it be more appropriate to enable gdbarch to be extended to enable the
more specific description of a particular target component and mode; as
opposed to pushing the requirement of a target to provide detailed register
etc. information about itself when all that should be necessary should be
for it to more specifically identify itself and present mode if any, thereby
enabling a correspondingly more precise gdbarch description to be selected
as the basis of it's logically visible model?




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