p An .Ft fp_except_t value is a bitmask specifying an exception type and containing any of the values listed below. l -column -offset indent FP_X_UFLxx t Dv FP_X_INV Ta Invalid Operation t Dv FP_X_DZ Ta Division by zero t Dv FP_X_OFL Ta Overflow t Dv FP_X_UFL Ta Underflow t Dv FP_X_IMP Ta Imprecision (inexact) t Dv FP_X_IOV Ta Integer Overflow .El
p An .Ft fp_prec_t specifies the precision of the floating point operations listed below. l -column -offset indent FP_RPS t Dv FP_PS Ta Dv 24 bit (single-precision) t Dv FP_PRS Ta reserved t Dv FP_PD Ta Dv 53 bit (double-precision) t Dv FP_PE Ta Dv 64 bit (extended-precision) .El
p The .Fn fpsetmask function will set the current exception mask, i.e., it will cause future operations with the specified result status to raise the .Dv SIGFPE exception. The .Fn fpgetmask function will return the current exception mask.
p The .Fn fpgetprec function will return the current floating point precision. The .Fn fpsetprec function will set the floating point precision and will return the previous precision.
p The .Fn fpsetround function will cause future operations to use the specified dynamic rounding mode. The .Fn fpgetround function will return the current rounding mode. l -tag -width Note:x t Em Note : On some architectures, instructions can optionally specify static rounding modes and exception enables that will supersede the specified dynamic mode. On other architectures, these features may not be fully supported. .El
p A .Dq sticky status word may be maintained in which a bit is set every time an exceptional floating point condition is encountered, whether or not a .Dv SIGFPE is generated. The .Fn fpsetsticky function will set or clear the specified exception history bits. The .Fn fpgetsticky function will return the exception history bits. .Sh RETURN VALUES The .Fn fpgetround and .Fn fpsetround functions return the
q previous rounding mode. The .Fn fpgetmask , .Fn fpsetmask , .Fn fpgetsticky , and .Fn fpsetsticky functions return the
q previous exception mask and exception history bits. .Sh SEE ALSO .Xr sigaction 2 , .Xr fenv 3 .Sh BUGS There is no way to return an unsupported value. Not all processors support all the modes. These interfaces are deprecated and the ones in .Xr fenv 3 should be used, although the interfaces in .Xr fenv 3 don't support getting or setting the precision.