Underflow Exception; Action - IBM A2 User Manual

Table of Contents

Advertisement

– Round toward –Infinity
For negative overflow, store –Infinity; for positive overflow, store the largest finite number of the for-
mat.
• FPR(FRT)  result
• FPSCR[FR]  undefined
• FPSCR[FI]  1
• FPSCR[FPRF] class and sign of the result (Infinity or Normal Number)

8.4.4 Underflow Exception

Underflow exception is defined separately for the enabled and disabled states:
• Enabled:
Underflow occurs when the intermediate result is "Tiny."
• Disabled:
Underflow occurs when the intermediate result is "Tiny" and there is "Loss of Accuracy."
A "Tiny" result is detected before rounding, when a nonzero intermediate result computed as though both the
precision and the exponent range were unbounded would be less in magnitude than the smallest normalized
number.
If the intermediate result is "Tiny" and underflow exception is disabled (FPSCR[UE] = 0), the intermediate
result is denormalized (See Normalization and Denormalization on page 138) and rounded (See Rounding
Modes on page 140) before being placed into the target FPR.
"Loss of Accuracy" is detected when the delivered result value differs from what would have been computed
were both the precision and the exponent range unbounded.

8.4.4.1 Action

The action to be taken depends on the setting of FPSCR[UE].
When underflow exception is enabled (FPSCR[UE] = 1) and exponent underflow occurs, the following actions
are taken:
• The Underflow Exception bit is set.
FPSCR[UX]  1
• For double-precision arithmetic instructions, the exponent of the normalized intermediate result is
adjusted by adding 1536.
• For single-precision arithmetic instructions and the frsp instruction, the exponent of the normalized inter-
mediate result is adjusted by adding 192.
• The adjusted rounded result is placed into the target FPR.
FPSCR[FPRF] class and sign of the result (Normalized Number)
Programming Note: The FR and FI bits are provided to allow the enabled exception type of program
interrupt, when taken because of an underflow exception, to simulate a "trap disabled" environment.
That is, the FR and FI bits allow the enabled exception type of program interrupt to unround the
result, thus allowing the result to be denormalized.
Version 1.3
October 23, 2012
User's Manual
A2 Processor
FU Interrupts and Exceptions
Page 379 of 864

Advertisement

Table of Contents
loading

Table of Contents