Prism 6.0 User's Guide

Displaying the Contents of Registers

You can examine the contents of registers in the same way that you examine the contents of memory. Specify a register by preceding its name with a dollar sign. For example,

$f0/

prints the contents of the X register.

Specify a number after the slash to print the contents of multiple registers. For example,

$f0/3

prints the contents of registers f0, f1, and f2. The order in which the registers are displayed is that shown in Table 4-1.

You can also specify a format, as described above. The format specifier controls the display of the output; it doesn't affect how much of the register contents is displayed. Thus,

$f0/3X

displays three registers; the output is displayed as hexadecimal longwords.

The registers in the UltraSPARC processor are listed in Table 4-2.

Table 4-2 UltraSPARC Registers

Name 

Register 

$g0-$g7

Global registers (64 bits) 

$o0-$o7

Output registers (64 bits) 

$l0-$l7

Local registers 

$i0-$i7

Input registers 

$psr

Processor state register 

$pc

Program counter 

$npc

Next program counter 

$y

Y register 

$wim

Window invalid mask 

$tbr

Trap base register 

$f0-$f31

Floating-point registers 

$fsr

Floating status register (64 bits) 

$f0f1-$f62f63

Floating-point registers 

$xg0-$xg7

Upper 32 bits of $g0-$g7 (SPARC V8 plus only, or higher)

$xo0-$xo7

Upper 32 bits of $o0-$o7 (SPARC V8 plus only, or higher)

$xfsr

Upper 32 bits of $fsr (SPARC V8 plus only, or higher)

$fprs

Floating-point registers state (SPARC V8 plus only, or higher) 

$tstate

Trap state register (SPARC V8 plus only, or higher) 

$fp

Frame pointer (synonym for $i6)

$sp

Stack pointer (synonym for $o6)