Extract Exponent (EXTREXP)


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


EXTREXPB 1C72 Branch options Receiver Source Branch targets


EXTREXPI 1872 Indicator options Receiver Source Indicator targets
Operand 1: Binary variable scalar.

Operand 2: Floating-point scalar.

Operand 3-6:

Description  This instruction extracts the exponent portion of a floating-point scalar source operand and places it into the receiver operand as a binary variable scalar.

The operands must be the numeric types indicated because no conversions are performed.

The source floating-point field is interrogated to determine the binary floating-point value represented and either a signed exponent, for number values, or a special identifier, for infinity and NaN values, is placed in the binary variable scalar receiver operand.

The value to be assigned to the receiver is dependent upon the floating-point value represented in the source operand as described below. It is a signed binary integer value and a numeric assignment of the value is made to the receiver.

When the source represents a normalized number, the biased exponent contained in the exponent field of the source is converted to the corresponding signed exponent by subtracting the bias of 127 for short or 1,023 for long to determine the value to be returned. The resulting value ranges from -126 to +127 for short format, -1,022 to +1,023 for long format. When the receiver is unsigned binary, a negative exponent will result in a size  (hex 0C0A) exception unless size exceptions are suppressed.

When the source represents a denormalized number, the value to be returned is determined by adjusting the signed exponent of the denormalized number. The signed exponent of a denormalized number is a fixed value of -126 for the short format and -1,022 for the long format. It is adjusted to the value the signed exponent would be if the source value was adjusted to a normalized number. The resulting value ranges from -127 to -149 for short format, -1,023 to -1,074 for long format.

When the source represents a value of zero, the value returned is zero.

When the source represents infinity, the value returned is +32,767.

When the source represents a not-a-number, the value returned is -32,768 for a signed binary receiver. For an unsigned binary(2) a value of 32,768 is returned, and for a unsigned binary(4) a value of 4,294,934,528 is returned.

Resultant Conditions 

Authorization Required

Lock Enforcement

Exceptions

06 Addressing

08 Argument/Parameter

10 Damage Encountered

0C Computation

1C Machine-Dependent

20 Machine Support

22 Object Access

24 Pointer Specification

2C Program Execution

2E Resource Control Limit

32 Scalar Specification

36 Space Management

44 Protection Violation