From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 2E6E43858C50; Fri, 12 Apr 2024 09:00:27 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 2E6E43858C50 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1712912427; bh=2HknaOokTU0JxZz80yFU7dad1FEEWBDz62oBJGmAKMo=; h=From:To:Subject:Date:In-Reply-To:References:From; b=F1htPrWXO5J9jvXjw0AxYX/p0mO9Ntgw12ieB82wpLLQt4HCAFQmS0vxXpR4DAHkg EHTMC/yNCAzxiBTbMCUBgS2nA/n8uCcl/+4d2S9TD2aXnNtGjeDpiMwcfiPrZITBZr MFwAb0zXHikil8vETMgKupVqZKxfvHVv485V7TIE= From: "cvs-commit at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug sanitizer/114687] [13/14 Regression] ICE: in edge_before_returns_twice_call, at gimple-iterator.cc:981 Date: Fri, 12 Apr 2024 09:00:24 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: sanitizer X-Bugzilla-Version: 14.0 X-Bugzilla-Keywords: ice-on-valid-code X-Bugzilla-Severity: normal X-Bugzilla-Who: cvs-commit at gcc dot gnu.org X-Bugzilla-Status: ASSIGNED X-Bugzilla-Resolution: X-Bugzilla-Priority: P1 X-Bugzilla-Assigned-To: jakub at gcc dot gnu.org X-Bugzilla-Target-Milestone: 13.3 X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: 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=3D114687 --- Comment #4 from GCC Commits --- The master branch has been updated by Jakub Jelinek : https://gcc.gnu.org/g:c9e94ae448ba309dba74de3ee1974a3ed9248889 commit r14-9933-gc9e94ae448ba309dba74de3ee1974a3ed9248889 Author: Jakub Jelinek Date: Fri Apr 12 10:59:54 2024 +0200 Limit special asan/ubsan/bitint returns_twice handling to calls in bbs = with abnormal pred [PR114687] The tree-cfg.cc verifier only diagnoses returns_twice calls preceded by non-label/debug stmts if it is in a bb with abnormal predecessor. The following testcase shows that if a user lies in the attributes (a function which never returns can't be pure, and can't return twice when it doesn't ever return at all), when we figure it out, we can remove the abnormal edges to the "returns_twice" call and perhaps whole .ABNORMAL_DISPATCHER etc. edge_before_returns_twice_call then ICEs because it can't find such an edge. The following patch limits the special handling to calls in bbs where the verifier requires that. 2024-04-12 Jakub Jelinek PR sanitizer/114687 * gimple-iterator.cc (gsi_safe_insert_before): Only use edge_before_returns_twice_call if bb_has_abnormal_pred. (gsi_safe_insert_seq_before): Likewise. * gimple-lower-bitint.cc (bitint_large_huge::lower_call): Only push to m_returns_twice_calls if bb_has_abnormal_pred. * gcc.dg/asan/pr114687.c: New test.=