diff options
author | Martin Liska <mliska@suse.cz> | 2022-10-26 13:07:57 +0200 |
---|---|---|
committer | Martin Liska <mliska@suse.cz> | 2022-10-28 09:16:24 +0200 |
commit | 3f9c071324eff2222249b23a7531e447fc17d928 (patch) | |
tree | 6eb26a9b2b9234ff6a41b74249d8ff2196cfaecc | |
parent | bd891730b26a6854d9b8f341bd43110085752007 (diff) | |
download | gcc-3f9c071324eff2222249b23a7531e447fc17d928.zip gcc-3f9c071324eff2222249b23a7531e447fc17d928.tar.gz gcc-3f9c071324eff2222249b23a7531e447fc17d928.tar.bz2 |
docs: document sanitizers can trigger warnings
PR sanitizer/107298
gcc/ChangeLog:
* doc/invoke.texi: Document sanitizers can trigger warnings.
-rw-r--r-- | gcc/doc/invoke.texi | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/gcc/doc/invoke.texi b/gcc/doc/invoke.texi index 9f0e546..c0ca765 100644 --- a/gcc/doc/invoke.texi +++ b/gcc/doc/invoke.texi @@ -16509,6 +16509,10 @@ by this option. @end table +Note the enabled sanitizer options tend to increase a false-positive rate +of selected warnings, most notably @option{-Wmaybe-uninitialized}. +And thus we recommend to disable @option{-Werror}. + While @option{-ftrapv} causes traps for signed overflows to be emitted, @option{-fsanitize=undefined} gives a diagnostic message. This currently works only for the C family of languages. |