From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 7593F3858423; Wed, 20 Oct 2021 06:40:12 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 7593F3858423 From: "cvs-commit at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/102642] [11/12 Regression] ICE in get, at cgraph.h:2776 since r12-4032-g701075864ac4d1c6 Date: Wed, 20 Oct 2021 06:40:12 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: c++ X-Bugzilla-Version: 12.0 X-Bugzilla-Keywords: error-recovery, ice-on-invalid-code X-Bugzilla-Severity: minor X-Bugzilla-Who: cvs-commit at gcc dot gnu.org X-Bugzilla-Status: ASSIGNED X-Bugzilla-Resolution: X-Bugzilla-Priority: P4 X-Bugzilla-Assigned-To: jakub at gcc dot gnu.org X-Bugzilla-Target-Milestone: 11.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 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: Wed, 20 Oct 2021 06:40:12 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D102642 --- Comment #5 from CVS Commits --- The master branch has been updated by Jakub Jelinek : https://gcc.gnu.org/g:424945258d1778617b5d3d5273f6e1c10e718f80 commit r12-4527-g424945258d1778617b5d3d5273f6e1c10e718f80 Author: Jakub Jelinek Date: Wed Oct 20 08:38:58 2021 +0200 c++: Fix up push_local_extern_decl_alias error recovery [PR102642] My recent push_local_extern_decl_alias change broke error-recovery, do_pushdecl can return error_mark_node and set_decl_tls_model can't be called on that. There are other code paths that store error_mark_node into DECL_LOCAL_DECL_ALIAS, with the intent to differentiate the cases where we haven't yet tried to push it into the namespace scope (NULL) and one where we have tried it but it failed (error_mark_node), but loo= king around, there are other spots where we call functions or do processing which doesn't tolerate error_mark_node. So, the first hunk with the testcase fixes the testcase, the others fix what I've spotted and the fix was easy to figure out (there are I t= hink 3 other spots mainly for function multiversioning). 2021-10-20 Jakub Jelinek PR c++/102642 * name-lookup.c (push_local_extern_decl_alias): Don't call set_decl_tls_model on error_mark_node. * decl.c (make_rtl_for_nonlocal_decl): Don't call set_user_assembler_name on error_mark_node. * parser.c (cp_parser_oacc_declare): Ignore DECL_LOCAL_DECL_ALI= AS if it is error_mark_node. (cp_parser_omp_declare_target): Likewise. * g++.dg/tls/pr102642.C: New test.=