From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id A0E7C385B1B3; Mon, 5 Dec 2022 22:58:27 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org A0E7C385B1B3 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1670281107; bh=k8yqvsIN9rwW1bOc2hGYjbuX1koxTH6TtAOy5GGKlbo=; h=From:To:Subject:Date:In-Reply-To:References:From; b=QrPfERaDxEabRhFGXyrR8Pkb5rvWoU485hX/J/XXVBT/+7bECEU/VpyeaV4cE/aTU WoRLWwGuRYlliARRtCRINerzmMokLQIjMJpRB5KUxJgKiXUS/HncA0t5562CLN+Iax zzBF98g6AXgNnP1ejA6AVIsvtfdbmaYeZ3NJED4w= From: "dmalcolm at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug analyzer/106325] -Wanalyzer-null-dereference false positive due to analyzer not making assumptions for `__attribute__((nonnull))` Date: Mon, 05 Dec 2022 22:58:26 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: analyzer X-Bugzilla-Version: 12.1.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: dmalcolm at gcc dot gnu.org X-Bugzilla-Status: NEW X-Bugzilla-Resolution: X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: dmalcolm at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: attachments.created Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 List-Id: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D106325 --- Comment #4 from David Malcolm --- Created attachment 54023 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=3D54023&action=3Dedit Reduced reproducer Attached is a reduced version of the reproducer, which demonstrates the fal= se +ve on trunk with just -fanalyzer on the command line: https://godbolt.org/z/fsec1f4hT and also with gcc 12, 11, and 10.=