aboutsummaryrefslogtreecommitdiff
path: root/gcc/doc
diff options
context:
space:
mode:
authorRichard Guenther <rguenther@suse.de>2007-01-25 12:35:13 +0000
committerRichard Biener <rguenth@gcc.gnu.org>2007-01-25 12:35:13 +0000
commit16c1c158d80c9ebc5b72c89fbe16c6622e8c35cf (patch)
tree38aed0de4ea56447e1382d524e34a85e4c8aed61 /gcc/doc
parent04a91788394a9f8dbea4bd528584c502cfd004e6 (diff)
downloadgcc-16c1c158d80c9ebc5b72c89fbe16c6622e8c35cf.zip
gcc-16c1c158d80c9ebc5b72c89fbe16c6622e8c35cf.tar.gz
gcc-16c1c158d80c9ebc5b72c89fbe16c6622e8c35cf.tar.bz2
invoke.texi (-Wcoverage-mismatch): Document.
2007-01-25 Richard Guenther <rguenther@suse.de> * doc/invoke.texi (-Wcoverage-mismatch): Document. * common.opt (-Wcoverage-mismatch): New warning option. * coverage.c (get_coverage_counts): Ignore coverage mismatch if -Wcoverage-mismatch is given. * gcc.dg/tree-prof/tree-prof.exp: Define _PROFILE_GENERATE and _PROFILE_USE. * gcc.dg/tree-prof/wcoverage-mismatch.c: New testcase. From-SVN: r121169
Diffstat (limited to 'gcc/doc')
-rw-r--r--gcc/doc/invoke.texi20
1 files changed, 19 insertions, 1 deletions
diff --git a/gcc/doc/invoke.texi b/gcc/doc/invoke.texi
index 18fee96..fee5871 100644
--- a/gcc/doc/invoke.texi
+++ b/gcc/doc/invoke.texi
@@ -225,7 +225,7 @@ Objective-C and Objective-C++ Dialects}.
-w -Wextra -Wall -Waggregate-return -Walways-true -Warray-bounds @gol
-Wno-attributes -Wc++-compat -Wc++0x-compat -Wcast-align -Wcast-qual @gol
-Wchar-subscripts -Wclobbered -Wcomment @gol
--Wconversion -Wno-deprecated-declarations @gol
+-Wconversion -Wcoverage-mismatch -Wno-deprecated-declarations @gol
-Wdisabled-optimization -Wno-div-by-zero @gol
-Wempty-body -Wno-endif-labels @gol
-Werror -Werror-* -Werror-implicit-function-declaration @gol
@@ -2282,6 +2282,20 @@ diagnostic emitted, which indicates which command line option directly
controls that diagnostic, when such an option is known to the
diagnostic machinery.
+@item -Wcoverage-mismatch
+@opindex Wcoverage-mismatch
+Warn if feedback profiles do not match when using the
+@option{-fprofile-use} option.
+If a source file was changed between @option{-fprofile-gen} and
+@option{-fprofile-use}, the files with the profile feedback can fail
+to match the source file and GCC can not use the profile feedback
+information. By default, GCC emits an error message in this case.
+The option @option{-Wcoverage-mismatch} emits a warning instead of an
+error. GCC does not use appropriate feedback profiles, so using this
+option can result in poorly optimized code. This option is useful
+only in the case of very minor changes such as bugfixes to an
+existing code-base.
+
@end table
@node Warning Options
@@ -5613,6 +5627,10 @@ generally profitable only with profile feedback available.
The following options are enabled: @code{-fbranch-probabilities}, @code{-fvpt},
@code{-funroll-loops}, @code{-fpeel-loops}, @code{-ftracer}
+By default, GCC emits an error message if the feedback profiles do not
+match the source code. This error can be turned into a warning by using
+@option{-Wcoverage-mismatch}. Note this may result in poorly optimized
+code.
@end table
The following options control compiler behavior regarding floating