HP 3000 Manuals

func nmbpindex [ System Debug Reference Manual ] MPE/iX 5.0 Documentation


System Debug Reference Manual

func nmbpindex 

Returns the NM breakpoint index for the NM breakpoint that has been set
at the specified NM code address.

Syntax 

     nmbpindex (virtaddr [pin])

This function accepts the address of an existing NM breakpoint and
returns the logical index number associated with that breakpoint.  The
default action is to look for breakpoints set by the current PIN.
Breakpoint indices for other PINs (including the global PIN) may be
retrieved by using the optional pin parameter.

Formal Declaration 

     nmbpindex:u32 (virtaddr:ptr [pin:s16=0])

Parameters 

 virtaddr        The address of an NM breakpoint whose index is to be
                 returned.

                 Virtaddr can be a short pointer, a long pointer, or a
                 full logical code pointer.

 pin             Look for breakpoints set by this PIN. Default is the
                 caller's PIN (a pin of 0 implies this).  To specify
                 system (global) breakpoints, use a -1 (or 32762) as the
                 PIN.

Examples 

      $nmdebug > bl 
      NM      [1] PROG $ c3.56d80   test_screen+$ab3
      NM      [2] PROG $ c3.4cf18   test_files
      NM     @[1] SYS  $ a.004b9130 FOPEN

First, list the existing breakpoints.

      $nmdebug > wl nmbpindex(test_files) 
      $2

Find the NM breakpoint index associated with the address test_files.

     $nmdebug > wl nmbpindex(FOPEN) 
     No breakpoint exists in the breakpoint tables with that address.
     (error #1080)
     Error evaluating a predefined function.  (error #4240)
       function is"nmbpindex"
         wl nmbpindex(FOPEN)

Now, go find the breakpoint index for the breakpoint at FOPEN . In this
example we get an error.  This is because we did not specify pin and thus
searched only for process local breakpoints.  We do not have a process
local breakpoint at FOPEN .

      $nmdebug > wl nmbpindex(FOPEN, -1) 
      $1

Find the breakpoint index for the breakpoint at FOPEN . This time we
specify a -1 to tell the function to search the list of system
breakpoints.

Limitations, Restrictions 

none



MPE/iX 5.0 Documentation