NonStop S-Series Server Description Manual (G06.24+)

TNS Instruction Set
HP NonStop S-Series Server Description Manual520331-003
11-25
Definitions of TNS Instructions
the result in R[7]. If any subscript is out of bounds, overflow is set. DCBA is then
deleted.
IDXD (000317). Calculate Index, Data Space. For an n-dimensional array, IDXD
compares the subscript values in n stack registers (B, C, D, and so on) against lower
and upper bounds in a table in the current data segment (2n + 1 words) specified by a
starting address in A. (The first word of the table in memory is the number of
dimensions; bit 0 is 1 if bounds checking is to be suppressed.) The element offset
value is computed and stored in register R[7]. Condition Code is set based on the
result in R[7]. If bounds checks are enabled and any subscript is out of bounds,
overflow is set. All stack data used is deleted.
IDXP (000347). Calculate Index, Code Space. For an n-dimensional array, IDXP
compares the subscript values in n stack registers (B, C, D, and so on) against lower
and upper bounds in a table in the current code segment (2n + 1 words) specified by a
starting address in A. (The first word of the table in memory is the number of
dimensions; bit 0 is 1 if bounds checking is to be suppressed.) The element offset
value is computed and stored in register R[7]. Condition Code is set based on the
result in R[7]. If bounds checks are enabled and any subscript is out of bounds,
overflow is set. All stack data used is deleted.
IMPY (000212). Integer Multiply A Times B. B is multiplied by A in integer (signed)
form. A and B are deleted from the stack and the result pushed on. Overflow is set if
the result is greater than 32767 or less than –32768. Condition Code is set.
INEG (000214). Integer Negate A. The signed integer in A is converted to its two’s-
complement form. Overflow is set if the original operand was –32768. Carry is set,
meaning no borrow. Condition Code is set.
ISUB (000211). Integer Subtract A From B. A is subtracted from B in integer (signed)
form. A and B are deleted, and the difference is pushed onto the stack. Overflow is
set if the result is greater than 32767 or less than –32768. Carry is set, meaning no
borrow. Condition Code is set.
LADD (000200). Logical Add A to B. A and B are added as 16-bit positive (unsigned)
integers. A and B are then deleted from the stack and the result pushed on. Carry is
set if the addition overflows bit 0. Condition Code is set.
LADI (003---). Logical Add Immediate Operand to A. The immediate operand is
pushed onto the stack, with the sign bit propagating into the high-order bits. Then A
and B are added in 16-bit unsigned integer form. A and B are then both deleted from
the stack and the result pushed on. Carry is set if the addition overflows bit 0.
Condition Code is set. Examples of the use of immediate operands are shown in
Figure 11-3 on page 11-4.
LADR (-70---). Load G-Relative Address of Variable Into A. The G-relative address of
the variable is pushed onto the stack. For binary coding details, refer to Table B-1 on
page B-1.