VxWorks API Reference : OS Libraries

dbgArchLib

NAME

dbgArchLib - architecture-dependent debugger library

ROUTINES

a0( ) - return the contents of register a0 (also a1 - a7) (MC680x0)
d0( ) - return the contents of register d0 (also d1 - d7) (MC680x0)
sr( ) - return the contents of the status register (MC680x0, SH)
dbgBpTypeBind( ) - bind a breakpoint handler to a breakpoint type (MIPS R3000, R4000, R4650)
edi( ) - return the contents of register edi (also esi - eax) (x86)
eflags( ) - return the contents of the status register (x86)
r0( ) - return the contents of register r0 (also r1 - r14) (ARM)
cpsr( ) - return the contents of the current processor status register (ARM)
psrShow( ) - display the meaning of a specified PSR value, symbolically (ARM)
r0( ) - return the contents of general register r0 (also r1-r15) (SH)
sr( ) - return the contents of control register sr (also gbr, vbr) (SH)
mach( ) - return the contents of system register mach (also macl, pr) (SH)
o0( ) - return the contents of register o0 (also o1-o7) (SimSolaris)
l0( ) - return the contents of register l0 (also l1-l7) (SimSolaris)
i0( ) - return the contents of register i0 (also i1-i7) (SimSolaris)
npc( ) - return the contents of the next program counter (SimSolaris)
psr( ) - return the contents of the processor status register (SimSolaris)
wim( ) - return the contents of the window invalid mask register (SimSolaris)
y( ) - return the contents of the y register (SimSolaris)
edi( ) - return the contents of register edi (also esi - eax) (x86/SimNT)
eflags( ) - return the contents of the status register (x86/SimNT)

DESCRIPTION

This module provides architecture-specific support functions for dbgLib. It also includes user-callable functions for accessing the contents of registers in a task's TCB (task control block). These routines include:

MC680x0:
a0( ) - a7( ) - address registers (a0 - a7)
d0( ) - d7( ) - data registers (d0 - d7)
sr( ) - status register (sr)
MIPS:
dbgBpTypeBind( ) - bind a breakpoint handler to a breakpoint type
x86/SimNT:
edi( ) - eax( ) - named register values
eflags( ) - status register value
SH:
r0( ) - r15( ) - general registers (r0 - r15)
sr( ) - status register (sr)
gbr( ) - global base register (gbr)
vbr( ) - vector base register (vbr)
mach( ) - multiply and accumulate register high (mach)
macl( ) - multiply and accumulate register low (macl)
pr( ) - procedure register (pr)
ARM:
r0( ) - r14( ) - general-purpose registers (r0 - r14)
cpsr( ) - current processor status reg (cpsr)
psrShow( ) - psr value, symbolically
SimSolaris:
g0( ) - g7( ) - global registers (g0 - g7)
o0( ) - o7( ) - out registers (o0 - o7, note lower-case "o")
l0( ) - l7( ) - local registers (l0 - l7, note lower-case "l")
i0( ) - i7( ) - in registers (i0 - i7)
npc( ) - next program counter (npc)
psr( ) - processor status register (psr)
wim( ) - window invalid mask (wim)
y( ) - y register

NOTE

The routine pc( ), for accessing the program counter, is found in usrLib.

SEE ALSO

dbgLib, VxWorks Programmer's Guide: Target Shell


OS Libraries : Routines

a0( )

NAME

a0( ) - return the contents of register a0 (also a1 - a7) (MC680x0)

SYNOPSIS

int a0
    (
    int taskId                /* task ID, 0 means default task */
    )

DESCRIPTION

This command extracts the contents of register a0 from the TCB of a specified task. If taskId is omitted or zero, the last task referenced is assumed.

Similar routines are provided for all address registers (a0 - a7): a0( ) - a7( ).

The stack pointer is accessed via a7( ).

RETURNS

The contents of register a0 (or the requested register).

SEE ALSO

dbgArchLib, VxWorks Programmer's Guide: Target Shell


OS Libraries : Routines

d0( )

NAME

d0( ) - return the contents of register d0 (also d1 - d7) (MC680x0)

SYNOPSIS

int d0
    (
    int taskId                /* task ID, 0 means default task */
    )

DESCRIPTION

This command extracts the contents of register d0 from the TCB of a specified task. If taskId is omitted or zero, the last task referenced is assumed.

Similar routines are provided for all data registers (d0 - d7): d0( ) - d7( ).

RETURNS

The contents of register d0 (or the requested register).

SEE ALSO

dbgArchLib, VxWorks Programmer's Guide: Target Shell


OS Libraries : Routines

sr( )

NAME

sr( ) - return the contents of the status register (MC680x0, SH)

SYNOPSIS

int sr
    (
    int taskId                /* task ID, 0 means default task */
    )

DESCRIPTION

This command extracts the contents of the status register from the TCB of a specified task. If taskId is omitted or zero, the last task referenced is assumed.

RETURNS

The contents of the status register.

SEE ALSO

dbgArchLib, VxWorks Programmer's Guide: Target Shell


OS Libraries : Routines

dbgBpTypeBind( )

NAME

dbgBpTypeBind( ) - bind a breakpoint handler to a breakpoint type (MIPS R3000, R4000, R4650)

SYNOPSIS

STATUS dbgBpTypeBind
    (
    int     bpType,           /* breakpoint type */
    FUNCPTR routine           /* function to bind */
    )

DESCRIPTION

Dynamically bind a breakpoint handler to breakpoints of type 0 - 7. By default only breakpoints of type zero are handled with the vxWorks breakpoint handler (see dbgLib). Other types may be used for Ada stack overflow or other such functions. The installed handler must take the same parameters as excExcHandle( ) (see excLib).

RETURNS

OK, or ERROR if bpType is out of bounds.

SEE ALSO

dbgArchLib, dbgLib, excLib


OS Libraries : Routines

edi( )

NAME

edi( ) - return the contents of register edi (also esi - eax) (x86)

SYNOPSIS

int edi
    (
    int taskId                /* task ID, 0 means default task */
    )

DESCRIPTION

This command extracts the contents of register edi from the TCB of a specified task. If taskId is omitted or zero, the last task referenced is assumed.

Similar routines are provided for all general registers (edi - eax): edi( ) - eax( ).

The stack pointer is accessed via eax( ).

RETURNS

The contents of register edi (or the requested register).

SEE ALSO

dbgArchLib, VxWorks Programmer's Guide: Debugging


OS Libraries : Routines

eflags( )

NAME

eflags( ) - return the contents of the status register (x86)

SYNOPSIS

int eflags
    (
    int taskId                /* task ID, 0 means default task */
    )

DESCRIPTION

This command extracts the contents of the status register from the TCB of a specified task. If taskId is omitted or zero, the last task referenced is assumed.

RETURNS

The contents of the status register.

SEE ALSO

dbgArchLib, VxWorks Programmer's Guide: Debugging


OS Libraries : Routines

r0( )

NAME

r0( ) - return the contents of register r0 (also r1 - r14) (ARM)

SYNOPSIS

int r0
    (
    int taskId                /* task ID, 0 means default task */
    )

DESCRIPTION

This command extracts the contents of register r0 from the TCB of a specified task. If taskId is omitted or zero, the last task referenced is assumed.

Similar routines are provided for registers (r1 - r14): r1( ) - r14( ).

RETURNS

The contents of register r0 (or the requested register).

SEE ALSO

dbgArchLib, VxWorks Programmer's Guide: Debugging


OS Libraries : Routines

cpsr( )

NAME

cpsr( ) - return the contents of the current processor status register (ARM)

SYNOPSIS

int cpsr
    (
    int taskId                /* task ID, 0 means default task */
    )

DESCRIPTION

This command extracts the contents of the status register from the TCB of a specified task. If taskId is omitted or zero, the last task referenced is assumed.

RETURNS

The contents of the current processor status register.

SEE ALSO

dbgArchLib, VxWorks Programmer's Guide: Debugging


OS Libraries : Routines

psrShow( )

NAME

psrShow( ) - display the meaning of a specified PSR value, symbolically (ARM)

SYNOPSIS

STATUS psrShow
    (
    UINT32 psrval             /* psr value to show */
    )

DESCRIPTION

This routine displays the meaning of all fields in a specified PSR value, symbolically.

RETURNS

OK, always.

SEE ALSO

dbgArchLib


OS Libraries : Routines

r0( )

NAME

r0( ) - return the contents of general register r0 (also r1-r15) (SH)

SYNOPSIS

int r0
    (
    int taskId                /* task ID, 0 means default task */
    )

DESCRIPTION

This command extracts the contents of register r0 from the TCB of a specified task. If taskId is omitted or zero, the last task referenced is assumed.

Similar routines are provided for all general registers (r1 - r15): r1( ) - r15( ).

RETURNS

The contents of register r0 (or the requested register).

SEE ALSO

dbgArchLib, VxWorks Programmer's Guide: Debugging


OS Libraries : Routines

sr( )

NAME

sr( ) - return the contents of control register sr (also gbr, vbr) (SH)

SYNOPSIS

int sr
    (
    int taskId                /* task ID, 0 means default task */
    )

DESCRIPTION

This command extracts the contents of register sr from the TCB of a specified task. If taskId is omitted or zero, the last task referenced is assumed.

Similar routines are provided for all control registers (gbr, vbr): gbr( ), vbr( ).

RETURNS

The contents of register sr (or the requested control register).

SEE ALSO

dbgArchLib, VxWorks Programmer's Guide: Debugging


OS Libraries : Routines

mach( )

NAME

mach( ) - return the contents of system register mach (also macl, pr) (SH)

SYNOPSIS

int mach
    (
    int taskId                /* task ID, 0 means default task */
    )

DESCRIPTION

This command extracts the contents of register mach from the TCB of a specified task. If taskId is omitted or zero, the last task referenced is assumed.

Similar routines are provided for other system registers (macl, pr): macl( ), pr( ). Note that pc( ) is provided by usrLib.c.

RETURNS

The contents of register mach (or the requested system register).

SEE ALSO

dbgArchLib, VxWorks Programmer's Guide: Debugging


OS Libraries : Routines

o0( )

NAME

o0( ) - return the contents of register o0 (also o1-o7) (SimSolaris)

SYNOPSIS

int o0
    (
    int taskId                /* task ID, 0 means default task */
    )

DESCRIPTION

This command extracts the contents of out register o0 from the TCB of a specified task. If taskId is omitted or 0, the current default task is assumed.

Similar routines are provided for all out registers (o0 - o7): o0( ) - o7( ).

The stack pointer is accessed via o6.

RETURNS

The contents of register o0 (or the requested register).

SEE ALSO

dbgArchLib, VxWorks Programmer's Guide: Debugging


OS Libraries : Routines

l0( )

NAME

l0( ) - return the contents of register l0 (also l1-l7) (SimSolaris)

SYNOPSIS

int l0
    (
    int taskId                /* task ID, 0 means default task */
    )

DESCRIPTION

This command extracts the contents of local register l0 from the TCB of a specified task. If taskId is omitted or 0, the current default task is assumed.

Similar routines are provided for all local registers (l0 - l7): l0( ) - l7( ).

RETURNS

The contents of register l0 (or the requested register).

SEE ALSO

dbgArchLib, VxWorks Programmer's Guide: Debugging


OS Libraries : Routines

i0( )

NAME

i0( ) - return the contents of register i0 (also i1-i7) (SimSolaris)

SYNOPSIS

int i0
    (
    int taskId                /* task ID, 0 means default task */
    )

DESCRIPTION

This command extracts the contents of in register i0 from the TCB of a specified task. If taskId is omitted or 0, the current default task is assumed.

Similar routines are provided for all in registers (i0 - i7): i0( ) - i7( ).

The frame pointer is accessed via i6.

RETURNS

The contents of register i0 (or the requested register).

SEE ALSO

dbgArchLib, VxWorks Programmer's Guide: Debugging


OS Libraries : Routines

npc( )

NAME

npc( ) - return the contents of the next program counter (SimSolaris)

SYNOPSIS

int npc
    (
    int taskId                /* task ID, 0 means default task */
    )

DESCRIPTION

This command extracts the contents of the next program counter from the TCB of a specified task. If taskId is omitted or 0, the current default task is assumed.

RETURNS

The contents of the next program counter.

SEE ALSO

dbgArchLib, ti( )


OS Libraries : Routines

psr( )

NAME

psr( ) - return the contents of the processor status register (SimSolaris)

SYNOPSIS

int psr
    (
    int taskId                /* task ID, 0 means default task */
    )

DESCRIPTION

This command extracts the contents of the processor status register from the TCB of a specified task. If taskId is omitted or 0, the default task is assumed.

RETURNS

The contents of the processor status register.

SEE ALSO

dbgArchLib, VxWorks Programmer's Guide: Debugging


OS Libraries : Routines

wim( )

NAME

wim( ) - return the contents of the window invalid mask register (SimSolaris)

SYNOPSIS

int wim
    (
    int taskId                /* task ID, 0 means default task */
    )

DESCRIPTION

This command extracts the contents of the window invalid mask register from the TCB of a specified task. If taskId is omitted or 0, the default task is assumed.

RETURNS

The contents of the window invalid mask register.

SEE ALSO

dbgArchLib, VxWorks Programmer's Guide: Debugging


OS Libraries : Routines

y( )

NAME

y( ) - return the contents of the y register (SimSolaris)

SYNOPSIS

int y
    (
    int taskId                /* task ID, 0 means default task */
    )

DESCRIPTION

This command extracts the contents of the y register from the TCB of a specified task. If taskId is omitted or 0, the default task is assumed.

RETURNS

The contents of the y register.

SEE ALSO

dbgArchLib, VxWorks Programmer's Guide: Debugging


OS Libraries : Routines

edi( )

NAME

edi( ) - return the contents of register edi (also esi - eax) (x86/SimNT)

SYNOPSIS

int edi
    (
    int taskId                /* task ID, 0 means default task */
    )

DESCRIPTION

This command extracts the contents of register edi from the TCB of a specified task. If taskId is omitted or zero, the last task referenced is assumed.

Similar routines are provided for all address registers (edi - eax): edi( ) - eax( ).

The stack pointer is accessed via eax( ).

RETURNS

The contents of register edi (or the requested register).

SEE ALSO

dbgArchLib, VxWorks Programmer's Guide: Debugging


OS Libraries : Routines

eflags( )

NAME

eflags( ) - return the contents of the status register (x86/SimNT)

SYNOPSIS

int eflags
    (
    int taskId                /* task ID, 0 means default task */
    )

DESCRIPTION

This command extracts the contents of the status register from the TCB of a specified task. If taskId is omitted or zero, the last task referenced is assumed.

RETURNS

The contents of the status register.

SEE ALSO

dbgArchLib, VxWorks Programmer's Guide: Debugging