[PATCH] Print vector registers in natural format, not hex

Klee Dienes klee@apple.com
Fri Oct 11 09:26:00 GMT 2002


Eli Zaretskii <eliz@is.elta.co.il> writes:

> Thanks, this is approved.
>
> Do we have facilities for printing vector registers?  If so, we should
> probably add a cross-reference to their description here.  The
> intersted reader will most probably wonder what can she do to print
> vector registers when she reads these passages.

The closest facility is the 'info vector' command, which by default 
prints the contents of all vector registers, but is documented simply 
as "Print the status of the vector unit.", which I take to mean that it 
can be overridden to have arch-specific output, much like 'info float'. 
  An 'info vector-registers' and 'info fp-registers' command might not 
be such a bad idea, but none exists at the moment that I know of.

We'll also probably need to look at the following chunk of 
documentation if/when this patch is accepted:

> @value{GDBN} always considers the contents of an ordinary register as 
> an
> integer when the register is examined in this way.  Some machines have
> special registers which can hold nothing but floating point; these
> registers are considered to have floating point values.  There is no 
> way
> to refer to the contents of an ordinary register as floating point 
> value
> (although you can @emph{print} it as a floating point value with
> @samp{print/f $@var{regname}}).

Maybe something along the lines of:

@value{GDBN} always considers the contents of an ordinary register as an
integer when the register is examined in this way.  Some machines have
special registers that are predefined to have specific types (typically 
floating
point or vector registers); these registers are printed according to 
their
system-defined type.  There is no way to refer to the contents of an 
ordinary
register as a floating point value or vector type (although you can 
@emph{print}
it as a floating point value with @samp{print/f $@var{regname}}).





More information about the Gdb-patches mailing list