Visit Our UNIX and Linux User Community

Linux and UNIX Man Pages

Test Your Knowledge in Computers #357
Difficulty: Medium
BusyBox includes an AWK implementation written by Linus Torvalds.
True or False?
Linux & Unix Commands - Search Man Pages

trpfpe(3f) [bsd man page]

TRPFPE(3F)																TRPFPE(3F)

NAME
trpfpe, fpecnt - trap and repair floating point faults SYNOPSIS
subroutine trpfpe (numesg, rtnval) double precision rtnval integer function fpecnt () common /fpeflt/ fperr logical fperr DESCRIPTION
NOTE: This routine applies only to Vax computers. It is a null routine on the PDP11. Trpfpe sets up a signal handler to trap arithmetic exceptions. If the exception is due to a floating point arithmetic fault, the result of the operation is replaced with the rtnval specified. Rtnval must be a double precision value. For example, ``0d0'' or ``dflmax()''. The first numesg occurrences of a floating point arithmetic error will cause a message to be written to the standard error file. Any exception that can't be repaired will result in the default action, typically an abort with core image. Fpecnt returns the number of faults since the last call to trpfpe. The logical value in the common block labelled fpeflt will be set to .true. each time a fault occurs. FILES
/usr/lib/libF77.a SEE ALSO
signal(3F), range(3F) BUGS
This routine works only for faults, not traps. This is primarily due to the Vax architecture. If the operation involves changing the stack pointer, it can't be repaired. This seldom should be a problem with the f77 compiler, but such an operation might be produced by the optimizer. The POLY and EMOD opcodes are not dealt with. 4.2 Berkeley Distribution May 15, 1985 TRPFPE(3F)

Check Out this Related Man Page

TRAPOV(3F)																TRAPOV(3F)

NAME
trapov - trap and repair floating point overflow SYNOPSIS
subroutine trapov (numesg, rtnval) double precision rtnval DESCRIPTION
NOTE: This routine applies only to the older VAX 11/780's. VAX computers made or upgraded since spring 1983 handle errors differently. See trpfpe(3F) for the newer error handler. This routine has always been ineffective on the VAX 11/750. It is a null routine on the PDP11. This call sets up signal handlers to trap arithmetic exceptions and the use of illegal operands. Trapping arithmetic exceptions allows the user's program to proceed from instances of floating point overflow or divide by zero. The result of such operations will be an illegal floating point value. The subsequent use of the illegal operand will be trapped and the operand replaced by the specified value. The first numesg occurrences of a floating point arithmetic error will cause a message to be written to the standard error file. If the resulting value is used, the value given for rtnval will replace the illegal operand generated by the arithmetic error. Rtnval must be a double precision value. For example, ``0d0'' or ``dflmax()''. FILES
/usr/lib/libF77.a SEE ALSO
trpfpe(3F), signal(3F), range(3F) BUGS
Other arithmetic exceptions can be trapped but not repaired. There is no way to distinguish between an integer value of 32768 and the illegal floating point form. Therefore such an integer value may get replaced while repairing the use of an illegal operand. 4.2 Berkeley Distribution May 15, 1985 TRAPOV(3F)

Featured Tech Videos