diff options
author | Neil Vachharajani <nvachhar@google.com> | 2010-05-04 23:45:58 +0000 |
---|---|---|
committer | Neil Vachharajani <nvachhar@gcc.gnu.org> | 2010-05-04 23:45:58 +0000 |
commit | 650cfcab96c03bae93fe5eceafce792e86a661e3 (patch) | |
tree | ea706642f18ee85392a51bf61e49a74bfbdef8bb /gcc/doc | |
parent | 55a46075763ff282cd457c3dc5e00483dae32230 (diff) | |
download | gcc-650cfcab96c03bae93fe5eceafce792e86a661e3.zip gcc-650cfcab96c03bae93fe5eceafce792e86a661e3.tar.gz gcc-650cfcab96c03bae93fe5eceafce792e86a661e3.tar.bz2 |
Sanitize the behavior of -Wcoverage-mismatch.
2010-05-04 Neil Vachharajani <nvachhar@google.com>
* doc/invoke.texi (-Wcoverage-mismatch): Updated documentation as
per new semantics.
* opts.c (decode_options): Enable -Werror=coverage-mismatch.
* coverage.c (get_coverage_counts): Always emit a warning. Adjust
conditions for printing notes.
* common.opt (-Wcoverage-mismatch): Allow negative, default to
true, update documentation.
* Makefile.in (coverage.o): Add dependence on DIAGNOSTIC_H and intl.h.
* testsuite/gcc.dg/tree-prof/wcoverage-mismatch.c: Adjusted.
From-SVN: r159050
Diffstat (limited to 'gcc/doc')
-rw-r--r-- | gcc/doc/invoke.texi | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/gcc/doc/invoke.texi b/gcc/doc/invoke.texi index b2fbd48..237f894 100644 --- a/gcc/doc/invoke.texi +++ b/gcc/doc/invoke.texi @@ -2755,12 +2755,13 @@ Warn if feedback profiles do not match when using the 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 bug fixes to an -existing code-base. +information. By default, this warning is enabled and is treated as an +error. @option{-Wno-coverage-mismatch} can be used to disable the +warning or @option{-Wno-error=coverage-mismatch} can be used to +disable the error. Disable the error for this warning can result in +poorly optimized code, so disabling the error is useful only in the +case of very minor changes such as bug fixes to an existing code-base. +Completely disabling the warning is not recommended. @end table |