From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 1851) id F24523857C77; Mon, 7 Nov 2022 08:55:21 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org F24523857C77 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1667811321; bh=XTaY0b4jLvExcb6fZFQpUUwfHAfBOEPbaubwIDUw0Nc=; h=From:To:Subject:Date:From; b=rMYLb5R2kRh2lrDEIntgtIpbHDxCo3l5TL9U3ueCCBZaAzgTf16ZXe1IgnGbCqhUi RJJFmOk9QOCHk2s0g4CYRsGmVQ4q1lEPHVOB/4vIM+T2yO+2XC4U/+ZYoV+oFaLRXb rKhtfNF3MCdZ3+hSMHCsZpDvIpu/lO1tA9ReYdLY= MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="utf-8" From: Martin Liska To: gcc-cvs@gcc.gnu.org Subject: [gcc r13-3748] docs: update: document sanitizers can trigger warnings X-Act-Checkin: gcc X-Git-Author: Martin Liska X-Git-Refname: refs/heads/master X-Git-Oldrev: 33dc1bacc3d4f13bf4f5bc321780452591c32861 X-Git-Newrev: a8fb90eb3949bfb101bd6f50f24a029e10119591 Message-Id: <20221107085521.F24523857C77@sourceware.org> Date: Mon, 7 Nov 2022 08:55:21 +0000 (GMT) List-Id: https://gcc.gnu.org/g:a8fb90eb3949bfb101bd6f50f24a029e10119591 commit r13-3748-ga8fb90eb3949bfb101bd6f50f24a029e10119591 Author: Martin Liska Date: Mon Nov 7 09:54:09 2022 +0100 docs: update: document sanitizers can trigger warnings gcc/ChangeLog: * doc/invoke.texi: Improve wording. Co-Authored-By: Gerald Pfeifer Diff: --- gcc/doc/invoke.texi | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/gcc/doc/invoke.texi b/gcc/doc/invoke.texi index 4a0fbca938e..94a2e20cfc1 100644 --- a/gcc/doc/invoke.texi +++ b/gcc/doc/invoke.texi @@ -16502,9 +16502,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}. +Note that sanitizers tend to increase the rate of false positive +warnings, most notably those around @option{-Wmaybe-uninitialized}. +We recommend against combining @option{-Werror} and [the use of] +sanitizers. While @option{-ftrapv} causes traps for signed overflows to be emitted, @option{-fsanitize=undefined} gives a diagnostic message.