Sun Studio 12: Fortran Library Reference floatingpoint.h: Fortran IEEE Definitions

The header file floatingpoint.h defines constants and types used to implement standard floating-point according to ANSI/IEEE Std 754-1985.

Include the file in a Fortran 95 source program as follows:

#include "floatingpoint.h"

Use of this include file requires preprocessing prior to Fortran compilation. The source file referencing this include file will automatically be preprocessed if the name has a .F, .F90 or .F95 extension.

IEEE Rounding Mode:


The type of the IEEE rounding direction mode. The order of enumeration varies according to hardware. 

SIGFPE Handling:


The type of a SIGFPE code.


The type of a user-definable SIGFPE exception handler called to handle a particular SIGFPE code.


A macro indicating default SIGFPE exception handling: IEEE exceptions to continue with a default result and to abort for other SIGFPE codes.


A macro indicating an alternate SIGFPE exception handling, namely to ignore and continue execution.


A macro indicating an alternate SIGFPE exception handling, namely to abort with a core dump.

IEEE Exception Handling:


The number of distinct IEEE floating-point exceptions. 


The type of the N_IEEE_EXCEPTION exceptions. Each exception is given a bit number.


The type intended to hold at least N_IEEE_EXCEPTION bits corresponding to the IEEE exceptions numbered by fp_exception_type. Thus, fp_inexact corresponds to the least significant bit and fp_invalid to the fifth least significant bit. Some operations can set more than one exception.

IEEE Classification:


A list of the classes of IEEE floating-point values and symbols. 

Refer to the Numerical Computation Guide. See also ieee_environment(3F).