Commit 567a90f5 by Paolo Bonzini Committed by H.J. Lu

re PR middle-end/39701 (Revision 145846 caused many test failures)

2009-04-10  Paolo Bonzini  <bonzini@gnu.org>

	PR tree-optimization/39701
	* doc/invoke.texi (Optimization Options): Document change in
	meaning and initialization of -fdelete-null-pointer-checks.

From-SVN: r145948
parent 1f544684
2009-04-10 Paolo Bonzini <bonzini@gnu.org>
PR tree-optimization/39701
* doc/invoke.texi (Optimization Options): Document change in
meaning and initialization of -fdelete-null-pointer-checks.
2009-04-10 H.J. Lu <hongjiu.lu@intel.com> 2009-04-10 H.J. Lu <hongjiu.lu@intel.com>
PR middle-end/39701 PR middle-end/39701
......
...@@ -5888,17 +5888,22 @@ Enabled at levels @option{-O}, @option{-O2}, @option{-O3}, @option{-Os}. ...@@ -5888,17 +5888,22 @@ Enabled at levels @option{-O}, @option{-O2}, @option{-O3}, @option{-Os}.
@item -fdelete-null-pointer-checks @item -fdelete-null-pointer-checks
@opindex fdelete-null-pointer-checks @opindex fdelete-null-pointer-checks
Use global dataflow analysis to identify and eliminate useless checks Assume that programs cannot safely dereference null pointers, and that
for null pointers. The compiler assumes that dereferencing a null no code or data element resides there. This enables simple constant
pointer would have halted the program. If a pointer is checked after folding optimizations at all optimization levels. In addition, other
it has already been dereferenced, it cannot be null. optimization passes in GCC use this flag to control global dataflow
analyses that eliminate useless checks for null pointers; these assume
In some environments, this assumption is not true, and programs can that if a pointer is checked after it has already been dereferenced,
safely dereference null pointers. Use it cannot be null.
@option{-fno-delete-null-pointer-checks} to disable this optimization
Note however that in some environments this assumption is not true.
Use @option{-fno-delete-null-pointer-checks} to disable this optimization
for programs which depend on that behavior. for programs which depend on that behavior.
Enabled by default. Some targets, especially embedded ones, disable this option at all levels.
Otherwise it is enabled at all levels: @option{-O0}, @option{-O1},
@option{-O2}, @option{-O3}, @option{-Os}. Passes that use the information
are enabled independently at different optimization levels.
@item -fexpensive-optimizations @item -fexpensive-optimizations
@opindex fexpensive-optimizations @opindex fexpensive-optimizations
......
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