123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175 |
- <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
- <html>
- <!-- Copyright (C) 1999-2017 Free Software Foundation, Inc.
- Permission is granted to copy, distribute and/or modify this document
- under the terms of the GNU Free Documentation License, Version 1.3 or
- any later version published by the Free Software Foundation; with the
- Invariant Sections being "Funding Free Software", the Front-Cover
- Texts being (a) (see below), and with the Back-Cover Texts being (b)
- (see below). A copy of the license is included in the section entitled
- "GNU Free Documentation License".
- (a) The FSF's Front-Cover Text is:
- A GNU Manual
- (b) The FSF's Back-Cover Text is:
- You have freedom to copy and modify this GNU Manual, like GNU
- software. Copies published by the Free Software Foundation raise
- funds for GNU development. -->
- <!-- Created by GNU Texinfo 5.2, http://www.gnu.org/software/texinfo/ -->
- <head>
- <title>The GNU Fortran Compiler: Debugging Options</title>
- <meta name="description" content="The GNU Fortran Compiler: Debugging Options">
- <meta name="keywords" content="The GNU Fortran Compiler: Debugging Options">
- <meta name="resource-type" content="document">
- <meta name="distribution" content="global">
- <meta name="Generator" content="makeinfo">
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
- <link href="index.html#Top" rel="start" title="Top">
- <link href="Option-Index.html#Option-Index" rel="index" title="Option Index">
- <link href="index.html#SEC_Contents" rel="contents" title="Table of Contents">
- <link href="Invoking-GNU-Fortran.html#Invoking-GNU-Fortran" rel="up" title="Invoking GNU Fortran">
- <link href="Directory-Options.html#Directory-Options" rel="next" title="Directory Options">
- <link href="Error-and-Warning-Options.html#Error-and-Warning-Options" rel="prev" title="Error and Warning Options">
- <style type="text/css">
- <!--
- a.summary-letter {text-decoration: none}
- blockquote.smallquotation {font-size: smaller}
- div.display {margin-left: 3.2em}
- div.example {margin-left: 3.2em}
- div.indentedblock {margin-left: 3.2em}
- div.lisp {margin-left: 3.2em}
- div.smalldisplay {margin-left: 3.2em}
- div.smallexample {margin-left: 3.2em}
- div.smallindentedblock {margin-left: 3.2em; font-size: smaller}
- div.smalllisp {margin-left: 3.2em}
- kbd {font-style:oblique}
- pre.display {font-family: inherit}
- pre.format {font-family: inherit}
- pre.menu-comment {font-family: serif}
- pre.menu-preformatted {font-family: serif}
- pre.smalldisplay {font-family: inherit; font-size: smaller}
- pre.smallexample {font-size: smaller}
- pre.smallformat {font-family: inherit; font-size: smaller}
- pre.smalllisp {font-size: smaller}
- span.nocodebreak {white-space:nowrap}
- span.nolinebreak {white-space:nowrap}
- span.roman {font-family:serif; font-weight:normal}
- span.sansserif {font-family:sans-serif; font-weight:normal}
- ul.no-bullet {list-style: none}
- -->
- </style>
- </head>
- <body lang="en" bgcolor="#FFFFFF" text="#000000" link="#0000FF" vlink="#800080" alink="#FF0000">
- <a name="Debugging-Options"></a>
- <div class="header">
- <p>
- Next: <a href="Directory-Options.html#Directory-Options" accesskey="n" rel="next">Directory Options</a>, Previous: <a href="Error-and-Warning-Options.html#Error-and-Warning-Options" accesskey="p" rel="prev">Error and Warning Options</a>, Up: <a href="Invoking-GNU-Fortran.html#Invoking-GNU-Fortran" accesskey="u" rel="up">Invoking GNU Fortran</a> [<a href="index.html#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="Option-Index.html#Option-Index" title="Index" rel="index">Index</a>]</p>
- </div>
- <hr>
- <a name="Options-for-debugging-your-program-or-GNU-Fortran"></a>
- <h3 class="section">2.5 Options for debugging your program or GNU Fortran</h3>
- <a name="index-options_002c-debugging"></a>
- <a name="index-debugging-information-options"></a>
- <p>GNU Fortran has various special options that are used for debugging
- either your program or the GNU Fortran compiler.
- </p>
- <dl compact="compact">
- <dt><code>-fdump-fortran-original</code></dt>
- <dd><a name="index-fdump_002dfortran_002doriginal"></a>
- <p>Output the internal parse tree after translating the source program
- into internal representation. Only really useful for debugging the
- GNU Fortran compiler itself.
- </p>
- </dd>
- <dt><code>-fdump-fortran-optimized</code></dt>
- <dd><a name="index-fdump_002dfortran_002doptimized"></a>
- <p>Output the parse tree after front-end optimization. Only really
- useful for debugging the GNU Fortran compiler itself.
- </p>
- </dd>
- <dt><code>-fdump-parse-tree</code></dt>
- <dd><a name="index-fdump_002dparse_002dtree"></a>
- <p>Output the internal parse tree after translating the source program
- into internal representation. Only really useful for debugging the
- GNU Fortran compiler itself. This option is deprecated; use
- <code>-fdump-fortran-original</code> instead.
- </p>
- </dd>
- <dt><code>-ffpe-trap=<var>list</var></code></dt>
- <dd><a name="index-ffpe_002dtrap_003dlist"></a>
- <p>Specify a list of floating point exception traps to enable. On most
- systems, if a floating point exception occurs and the trap for that
- exception is enabled, a SIGFPE signal will be sent and the program
- being aborted, producing a core file useful for debugging. <var>list</var>
- is a (possibly empty) comma-separated list of the following
- exceptions: ‘<samp>invalid</samp>’ (invalid floating point operation, such as
- <code>SQRT(-1.0)</code>), ‘<samp>zero</samp>’ (division by zero), ‘<samp>overflow</samp>’
- (overflow in a floating point operation), ‘<samp>underflow</samp>’ (underflow
- in a floating point operation), ‘<samp>inexact</samp>’ (loss of precision
- during operation), and ‘<samp>denormal</samp>’ (operation performed on a
- denormal value). The first five exceptions correspond to the five
- IEEE 754 exceptions, whereas the last one (‘<samp>denormal</samp>’) is not
- part of the IEEE 754 standard but is available on some common
- architectures such as x86.
- </p>
- <p>The first three exceptions (‘<samp>invalid</samp>’, ‘<samp>zero</samp>’, and
- ‘<samp>overflow</samp>’) 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.
- </p>
- <p>Many, if not most, floating point operations incur loss of precision
- due to rounding, and hence the <code>ffpe-trap=inexact</code> is likely to
- be uninteresting in practice.
- </p>
- <p>By default no exception traps are enabled.
- </p>
- </dd>
- <dt><code>-ffpe-summary=<var>list</var></code></dt>
- <dd><a name="index-ffpe_002dsummary_003dlist"></a>
- <p>Specify a list of floating-point exceptions, whose flag status is printed
- to <code>ERROR_UNIT</code> when invoking <code>STOP</code> and <code>ERROR STOP</code>.
- <var>list</var> can be either ‘<samp>none</samp>’, ‘<samp>all</samp>’ or a comma-separated list
- of the following exceptions: ‘<samp>invalid</samp>’, ‘<samp>zero</samp>’, ‘<samp>overflow</samp>’,
- ‘<samp>underflow</samp>’, ‘<samp>inexact</samp>’ and ‘<samp>denormal</samp>’. (See
- <samp>-ffpe-trap</samp> for a description of the exceptions.)
- </p>
- <p>By default, a summary for all exceptions but ‘<samp>inexact</samp>’ is shown.
- </p>
- </dd>
- <dt><code>-fno-backtrace</code></dt>
- <dd><a name="index-fno_002dbacktrace"></a>
- <a name="index-backtrace"></a>
- <a name="index-trace"></a>
- <p>When a serious runtime error is encountered or a deadly signal is
- emitted (segmentation fault, illegal instruction, bus error,
- floating-point exception, and the other POSIX signals that have the
- action ‘<samp>core</samp>’), the Fortran runtime library tries to output a
- backtrace of the error. <code>-fno-backtrace</code> disables the backtrace
- generation. This option only has influence for compilation of the
- Fortran main program.
- </p>
- </dd>
- </dl>
- <p>See <a href="http://gcc.gnu.org/onlinedocs/gcc/Debugging-Options.html#Debugging-Options">Options for Debugging Your Program or GCC</a> in <cite>Using the GNU Compiler Collection (GCC)</cite>, for more information on
- debugging options.
- </p>
- <hr>
- <div class="header">
- <p>
- Next: <a href="Directory-Options.html#Directory-Options" accesskey="n" rel="next">Directory Options</a>, Previous: <a href="Error-and-Warning-Options.html#Error-and-Warning-Options" accesskey="p" rel="prev">Error and Warning Options</a>, Up: <a href="Invoking-GNU-Fortran.html#Invoking-GNU-Fortran" accesskey="u" rel="up">Invoking GNU Fortran</a> [<a href="index.html#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="Option-Index.html#Option-Index" title="Index" rel="index">Index</a>]</p>
- </div>
- </body>
- </html>
|