Op Code (Hex) | Extender | Operand 1 | Operand 2 | Operand 3 [4-6] |
---|---|---|---|---|
CMPPSPADB 1CE6 | Branch options | Compare operand 1 | Compare operand 2 | Branch targets |
| ||||
CMPPSPADI 18E6 | Indicator options | Compare Operand 1 | Compare Operand 2 | Indicator targets |
Operand 2: Numeric variable scalar, character variable scalar, numeric variable array, character variable array, space pointer, or data pointer.
Operand 3 [4-6]:
Description: The space addressability contained in the pointer specified by operand 1 is compared with the space addressability defined by operand 2.
The value of the operand 1 pointer is compared based on the following:
Based on the results of the comparison, the resulting condition is used with the extender to transfer control (branch form) or to assign a value to each of the indicator operands (indicator form). If the operands are not in the same space, the resultant condition is unequal. If the operands are in the same space and the offset into the space of operand 1 is larger or smaller than the offset of operand 2, the resultant condition is high or low, respectively. An equal condition occurs only if the operands are in the same space at the same offset. Therefore, the resultant conditions (high, low, equal, and unequal) are mutually exclusive. Consequently, if you specify that an action be taken upon the nonexistence of a condition, this results in the action being taken upon the occurrence of any of the other three possible conditions. For example, a branch not high would result in the branch being taken on a low, equal, or unequal condition.
The object destroyed (hex 2202) exception, parameter reference violation (hex 0801) exception, and pointer does not exist (hex 2401) exception are not signaled when operand 1 or operand 2 is a space pointer machine object or when operand 2 is a scalar based on a space pointer machine object. This occurs when the space pointer machine object contains an internal machine value that indicates one of these error conditions exists. If the corresponding exception is not signaled, the resulting condition of the comparison operation is not defined other than that it will be one of the four valid resultant conditions for this instruction.
When the Override Program Attributes (OVRPGATR) instruction is used to override this instruction, the pointer does not exist (hex 2401) exception is not signaled when operand 1 or operand 2 is a space pointer (i.e. either a space pointer data object or a space pointer machine object). Furthermore, some comparisons involving space pointers are defined even when one or both of the compare operands is a pointer subject to the pointer does not exist condition. Specifically, if both compare operands are subject to the pointer does not exist condition, the resultant condition is equal. When one space pointer is set and one is subject to the pointer does not exist condition, the resultant condition is unequal, but undefined with respect to comparisons which include specification of the high or low conditions.
06 Addressing
08 Argument/Parameter
10 Damage Encountered
1C Machine-Dependent
20 Machine Support
22 Object Access
24 Pointer Specification
2E Resource Control Limit
36 Space Management
44 Protection Violation