From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id F17E43858031; Tue, 16 Nov 2021 09:19:00 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org F17E43858031 From: "cvs-commit at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug tree-optimization/102009] [12 Regression] ICE: in gimple_call_arg, at gimple.h:3272 by r12-2976 Date: Tue, 16 Nov 2021 09:19:00 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: tree-optimization X-Bugzilla-Version: 12.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: 12.0 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 X-BeenThere: gcc-bugs@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-bugs mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 16 Nov 2021 09:19:01 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D102009 --- Comment #4 from CVS Commits --- The master branch has been updated by Jakub Jelinek : https://gcc.gnu.org/g:eacdfaf7ca07367ede1a0c50aa997953958dabae commit r12-5294-geacdfaf7ca07367ede1a0c50aa997953958dabae Author: Jakub Jelinek Date: Tue Nov 16 10:18:25 2021 +0100 waccess: Fix up pass_waccess::check_alloc_size_call [PR102009] This function punts if the builtins have no arguments, but as can be se= en on the testcase, even if it has some arguments but alloc_size attribute= 's arguments point to arguments that aren't passed, we get a warning earli= er from the FE but should punt rather than ICE on it. Other users of alloc_size attribute e.g. in tree-object-size.c (alloc_object_size) punt similarly and similarly even in the same TU maybe_warn_nonstring_arg correctly verifies calls h= ave enough arguments. 2021-11-16 Jakub Jelinek PR tree-optimization/102009 * gimple-ssa-warn-access.cc (pass_waccess::check_alloc_size_cal= l): Punt if any of alloc_size arguments is out of bounds vs. number= of call arguments. * gcc.dg/pr102009.c: New test.=