GNU Fortran has various special options that are used for debugging either your program or the GNU Fortran compiler.
-fdump-fortran-original
-fdump-fortran-optimized
-fdump-parse-tree
-fdump-fortran-original
instead. -ffpe-trap=
list
invalid
’ (invalid floating point operation, such as SQRT(-1.0)
), ‘zero
’ (division by zero), ‘overflow
’ (overflow in a floating point operation), ‘underflow
’ (underflow in a floating point operation), ‘inexact
’ (loss of precision during operation), and ‘denormal
’ (operation performed on a denormal value). The first five exceptions correspond to the five IEEE 754 exceptions, whereas the last one (‘denormal
’) is not part of the IEEE 754 standard but is available on some common architectures such as x86. The first three exceptions (‘invalid
’, ‘zero
’, and ‘overflow
’) often indicate serious errors, and unless the program has provisions for dealing with these exceptions, enabling traps for these three exceptions is probably a good idea.
Many, if not most, floating point operations incur loss of precision due to rounding, and hence the ffpe-trap=inexact
is likely to be uninteresting in practice.
By default no exception traps are enabled.
-ffpe-summary=
list
ERROR_UNIT
when invoking STOP
and ERROR STOP
. list can be either ‘none
’, ‘all
’ or a comma-separated list of the following exceptions: ‘invalid
’, ‘zero
’, ‘overflow
’, ‘underflow
’, ‘inexact
’ and ‘denormal
’. (See -ffpe-trap
for a description of the exceptions.) By default, a summary for all exceptions but ‘inexact
’ is shown.
-fno-backtrace
core
’), the Fortran runtime library tries to output a backtrace of the error. -fno-backtrace
disables the backtrace generation. This option only has influence for compilation of the Fortran main program. See Options for Debugging Your Program or GCC, for more information on debugging options.
© Free Software Foundation
Licensed under the GNU Free Documentation License, Version 1.3.
https://gcc.gnu.org/onlinedocs/gcc-5.4.0/gfortran/Debugging-Options.html