Commit 267cca3d by Roman Zhuykov

doc: properly describe --enable-checking behavior

This patch rewords the whole description to fix minor issues:
 - documents 'gimple' and 'types' checks,
 - clarifies what happens when option is used without '=list',
 - fixes inaccurate wrong wording about release snapshots,
 - describes that release checks can only de disabled explicitly.

gcc/ChangeLog:
	* doc/install.texi (--enable-checking): Properly document current
	behavior.
	(--enable-stage1-checking): Minor clarification about bootstrap.
parent f2ca2088
2020-02-24 Roman Zhuykov <zhroma@ispras.ru>
* doc/install.texi (--enable-checking): Properly document current
behavior.
(--enable-stage1-checking): Minor clarification about bootstrap.
2020-02-24 David Malcolm <dmalcolm@redhat.com> 2020-02-24 David Malcolm <dmalcolm@redhat.com>
PR analyzer/93032 PR analyzer/93032
......
...@@ -1839,41 +1839,48 @@ final releases. The specific files which get @option{-Werror} are ...@@ -1839,41 +1839,48 @@ final releases. The specific files which get @option{-Werror} are
controlled by the Makefiles. controlled by the Makefiles.
@item --enable-checking @item --enable-checking
@itemx --disable-checking
@itemx --enable-checking=@var{list} @itemx --enable-checking=@var{list}
When you specify this option, the compiler is built to perform internal This option controls performing internal consistency checks in the compiler.
consistency checks of the requested complexity. This does not change the It does not change the generated code, but adds error checking of the
generated code, but adds error checking within the compiler. This will requested complexity. This slows down the compiler and may only work
slow down the compiler and may only work properly if you are building properly if you are building the compiler with GCC@.
the compiler with GCC@. This is @samp{yes,extra} by default when building
from the source repository or snapshots, but @samp{release} for releases. The default When the option is not specified, the active set of checks depends on context.
for building the stage1 compiler is @samp{yes}. More control Namely, bootstrap stage 1 defaults to @samp{--enable-checking=yes}, builds
over the checks may be had by specifying @var{list}. The categories of from release archives default to @samp{--enable-checking=release}, and
checks available are @samp{yes} (most common checks otherwise @samp{--enable-checking=yes,extra} is used. When the option is
@samp{assert,misc,tree,gc,rtlflag,runtime}), @samp{no} (no checks at specified without a @var{list}, the result is the same as
all), @samp{all} (all but @samp{valgrind}), @samp{release} (cheapest @samp{--enable-checking=yes}. Likewise, @samp{--disable-checking} is
checks @samp{assert,runtime}) or @samp{none} (same as @samp{no}). equivalent to @samp{--enable-checking=no}.
Individual checks can be enabled with these flags @samp{assert},
@samp{df}, @samp{fold}, @samp{gc}, @samp{gcac}, @samp{misc}, @samp{rtl}, The categories of checks available in @var{list} are @samp{yes} (most common
@samp{rtlflag}, @samp{runtime}, @samp{tree}, @samp{extra} and @samp{valgrind}. checks @samp{assert,misc,gc,gimple,rtlflag,runtime,tree,types}), @samp{no}
@samp{extra} adds for @samp{misc} checking extra checks that might affect (no checks at all), @samp{all} (all but @samp{valgrind}), @samp{release}
code generation and should therefore not differ between stage1 and later (cheapest checks @samp{assert,runtime}) or @samp{none} (same as @samp{no}).
stages. @samp{release} checks are always on and to disable them
@samp{--disable-checking} or @samp{--enable-checking=no[,<other checks>]}
The @samp{valgrind} check requires the external @command{valgrind} must be explicitly requested. Disabling assertions makes the compiler and
simulator, available from @uref{http://valgrind.org/}. The runtime slightly faster but increases the risk of undetected internal errors
@samp{df}, @samp{rtl}, @samp{gcac} and @samp{valgrind} checks are very expensive. causing wrong code to be generated.
To disable all checking, @samp{--disable-checking} or
@samp{--enable-checking=none} must be explicitly requested. Disabling Individual checks can be enabled with these flags: @samp{assert}, @samp{df},
assertions will make the compiler and runtime slightly faster but @samp{extra}, @samp{fold}, @samp{gc}, @samp{gcac}, @samp{gimple},
increase the risk of undetected internal errors causing wrong code to be @samp{misc}, @samp{rtl}, @samp{rtlflag}, @samp{runtime}, @samp{tree},
generated. @samp{types} and @samp{valgrind}. @samp{extra} extends @samp{misc}
checking with extra checks that might affect code generation and should
therefore not differ between stage1 and later stages in bootstrap.
The @samp{valgrind} check requires the external @command{valgrind} simulator,
available from @uref{http://valgrind.org/}. The @samp{df}, @samp{rtl},
@samp{gcac} and @samp{valgrind} checks are very expensive.
@item --disable-stage1-checking @item --disable-stage1-checking
@itemx --enable-stage1-checking @itemx --enable-stage1-checking
@itemx --enable-stage1-checking=@var{list} @itemx --enable-stage1-checking=@var{list}
If no @option{--enable-checking} option is specified the stage1 This option affects only bootstrap build. If no @option{--enable-checking}
compiler will be built with @samp{yes} checking enabled, otherwise option is specified the stage1 compiler is built with @samp{yes} checking
the stage1 checking flags are the same as specified by enabled, otherwise the stage1 checking flags are the same as specified by
@option{--enable-checking}. To build the stage1 compiler with @option{--enable-checking}. To build the stage1 compiler with
different checking options use @option{--enable-stage1-checking}. different checking options use @option{--enable-stage1-checking}.
The list of checking options is the same as for @option{--enable-checking}. The list of checking options is the same as for @option{--enable-checking}.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment