Add Space Pointer (ADDSPP)

Instruction Syntax

Op Code (Hex) Operand 1 Operand 2 Operand 3
0083 Receiver pointer Source pointer Increment
Operand 1: Space pointer.

Operand 2: Space pointer.

Operand 3: Binary scalar.

Description:

This instruction adds a signed or unsigned binary value to the offset of a space pointer. The value of the binary scalar represented by operand 3 is added to the space address contained in the space pointer specified by operand 2, and the result is stored in the space pointer identified by operand 1. I.e.

    Operand 1 = Operand 2 + Operand 3

Operand 3 can have a positive or negative value. The space that the pointer is addressing is not changed by the instruction.

Operand 2 must contain a space pointer; otherwise, a pointer type invalid (hex 2402) exception is signaled.

When the addressability in the space pointer is modified, the instruction signals a space addressing violation (hex 0601) exception when one of the following conditions occurs, for any space except teraspace:

  • The space address to be stored in the pointer has a negative offset value.
  • The offset addresses beyond the largest space allocatable in the object. This maximum offset value is dependent on the size and packaging of the object containing the space and is independent of the actual size of the space allocated.
If the exception is signaled by this instruction for one of these reasons, the pointer is not modified by the instruction.

In contrast, when modifying the addressability of a space pointer to teraspace, if the address computed either overflows or underflows the offset, the result is wrapped back within teraspace and no exception is signalled. However, since the size of teraspace and thus the size of the offset portion of a teraspace address is implementation-dependent, the wrapped result may vary between machine implementations.

Attempts to use a pointer whose offset value lies: between the currently allocated extent of the space and the maximum allocatable extent of the space, or whose offset is outside all teraspace allocations, cause the space addressing violation (hex 0601) exception to be signaled.

The object destroyed (hex 2202) exception, parameter reference violation (hex 0801) exception, and pointer does not exist (hex 2401) exception may not be signaled when operand 2 contains an internal machine value that indicates one of these error conditions exists. If the corresponding exception is not signaled during this operation, operand 1 is set with an internal machine value that will cause either the same exception or a space addressing violation (hex 0601) exception if a subsequent attempt is made to reference space data using the operand 1 pointer.

Authorization Required

  • None

Lock Enforcement

  • None

Exceptions

  • 06 Addressing
    • 0601 Space Addressing Violation
    • 0602 Boundary Alignment
    • 0603 Range
  • 08 Argument/Parameter
    • 0801 Parameter Reference Violation
  • 10 Damage Encountered
    • 1004 System Object Damage State
    • 1044 Partial System Object Damage
  • 1C Machine-Dependent
    • 1C03 Machine Storage Limit Exceeded
  • 20 Machine Support
    • 2002 Machine Check
    • 2003 Function Check
  • 22 Object Access
    • 2201 Object Not Found
    • 2202 Object Destroyed
    • 2203 Object Suspended
    • 2208 Object Compressed
    • 220B Object Not Available
  • 24 Pointer Specification
    • 2401 Pointer Does Not Exist
    • 2402 Pointer Type Invalid
  • 2E Resource Control Limit
    • 2E01 User Profile Storage Limit Exceeded
  • 36 Space Management
    • 3601 Space Extension/Truncation
  • 44 Protection Violation
    • 4401 Object Domain or Hardware Storage Protection Violation
    • 4402 Literal Values Cannot Be Changed