Extract Magnitude (EXTRMAG)


Op Code (Hex) Extender Operand 1 Operand 2 Operand [3-6]
EXTRMAG 1052
Receiver Source


EXTRMAGI 1852 Indicator options Receiver Source Indicator targets


EXTRMAGB 1C52 Branch options Receiver Source Branch targets
Operand 1: Numeric variable scalar.

Operand 2: Numeric scalar.

Operand 3-6:

Short forms


Op Code (Hex) Extender Operand 1 Operand [2-5]
EXTRMAGS 1152
Receiver/Source



EXTRMAGIS 1952 Indicator options Receiver/Source Indicator targets


EXTRMAGBS 1D52 Branch options Receiver/Source Branch targets
Operand 1: Numeric variable scalar.

Operand 2-5:

Description  The numeric value of the source operand is converted to its absolute value and placed in the numeric variable scalar receiver operand.

The absolute value is formed from the source operand as follows:

The result of the operation is copied into the receiver operand according to the rules of the Copy Numeric Value (CPYNV) instruction. If this operand is not the same type as that used in performing the operation, the resultant value is converted to its type. If necessary, the resultant value is adjusted to the length of the receiver operand, or aligned at the assumed decimal point of the receiver operand, or both before being copied to it. Length adjustment and decimal point alignment are performed according to the rules of arithmetic operations outlined in Arithmetic Operations. If significant digits are truncated on the left end of the resultant value, a size (hex 0C0A) exception is signaled. An attempt to extract the magnitude of a maximum negative binary value to a binary scalar of the same size also results in a size  (hex 0C0A) exception.

When the source floating-point operand represents not-a-number, the sign field of the source is not forced to positive and this value is not altered in the receiver.

If a decimal to binary conversion causes a size  (hex 0C0A) exception to be signaled, the binary value contains the correct truncated result only if the decimal value contains 15 or fewer significant nonfractional digits.

For a fixed-point operation, if significant digits are truncated from the left end of the resultant value, a size  (hex 0C0A) exception is signaled. An attempt to extract the absolute value of a maximum negative binary value into a binary scalar of the same size also results in a size  (hex 0C0A) exception.

For floating-point operations that involve a fixed-point receiver field, if nonzero digits would be truncated from the left end of the resultant value, an invalid floating-point conversion  (hex 0C0C) exception is signaled.

For a floating-point receiver operand, if the exponent of the resultant value is either too large or too small to be represented in the receiver, the floating-point overflow  (hex 0C06) exception or the floating-point underflow  (hex 0C07) exception is signaled.

Resultant Conditions 

Authorization Required

Lock Enforcement

Exceptions

06 Addressing

08 Argument/Parameter

0C Computation

10 Damage Encountered

1C Machine-Dependent

20 Machine Support

22 Object Access

24 Pointer Specification

2C Program Execution

2E Resource Control Limit

36 Space Management

44 Protection Violation