Browse Prior Art Database

# Exponent Overflow/underflow During Conversion of Floating-point Numbers

IP.com Disclosure Number: IPCOM000060657D
Original Publication Date: 1986-Apr-01
Included in the Prior Art Database: 2005-Mar-09
Document File: 2 page(s) / 13K

IBM

## Related People

Aggarwal, BK: AUTHOR [+3]

## Abstract

A technique is described whereby exponent bias corrections are uniquely formulated when exponent overflow or underflow conditions are detected during the process of converting the representation of a floating point number in one precision representation with lesser precision.

This text was extracted from a PDF file.
This is the abbreviated version, containing approximately 52% of the total text.

Page 1 of 2

Exponent Overflow/underflow During Conversion of Floating-point Numbers

A technique is described whereby exponent bias corrections are uniquely formulated when exponent overflow or underflow conditions are detected during the process of converting the representation of a floating point number in one precision representation with lesser precision.

It is common in floating-point computer architecture to provide state latches that control the results produced when an exponent overflow or exponent underflow condition is detected. In one state, say, the reset state, a default value is produced. In the other state, a specially coded value is produced that is passed to program, frequently termed a "trap handler", that acts to preserve the numeric value of the results even though it cannot be represented in the architected format.

Some floating-point architectures define representations of floating point numbers in more than one precision where a representation of greater precision also provides a greater exponent range. In such architectures, there is a problem in preserving the numeric value when converting to a lesser precision if the number being converted is outside the range that can be represented. This technique provides a solution to this problem.

This technique requires that the storage available for the results be capable of holding the number of bits needed to represent the exponent of the representation of the greater precision as shown in Fig. 1. When converting from a longer precision to a shorter precision, the significand is rounded. If the rounded result is in a range that can be represented in the shorter precision format then a normal result is generated. If this is not the case, then an overflow or underflow condition exists, and if the corresponding state latch is set to indicate that the value is to be preserved for the "trap handler", then the exponent representation of the longer precision is used.

When an overflow or underflow condition exits, a bias correction factor is applied to the exponent value before it is stored. First, the overflow case i...