From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 89C68385E014; Thu, 26 Mar 2020 13:21:58 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 89C68385E014 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1585228918; bh=qapP9EU36N/54qXtHRbYJWBBNy0wxNZcNe8SxI/7ZIg=; h=From:To:Subject:Date:In-Reply-To:References:From; b=Gm122BMN6YR1CIzKiK66nejFVZQdt5Sm9yjtVo921/zFEMLoor+1IEdjzXq0fwAug av2vVQqy0QVI2YRWNQ5D0ZNckWkLvWNMinu4wzGRYfSj21sFz9pCp++6N/4VqrRVXo cSQMRMuyvMDj1vJLx8e3cD2O2sr5LvfLDu1vX5bA= From: "rguenth at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug debug/94273] [10 Regression] ICE in splice_child_die, at dwarf2out.c:5657 since r10-7235-g52b3aa8be1893848 Date: Thu, 26 Mar 2020 13:21:58 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: debug X-Bugzilla-Version: 10.0 X-Bugzilla-Keywords: ice-on-valid-code X-Bugzilla-Severity: normal X-Bugzilla-Who: rguenth at gcc dot gnu.org X-Bugzilla-Status: NEW X-Bugzilla-Resolution: X-Bugzilla-Priority: P1 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: 10.0 X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: cc 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: Thu, 26 Mar 2020 13:21:58 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D94273 Richard Biener changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |rguenth at gcc dot gnu.org --- Comment #6 from Richard Biener --- (In reply to Alexey Neyman from comment #4) > Or add a similar "return if debug level is terse" at the beginning of > `gen_type_die` - I didn't notice that in C++ it could also get called not > through the `add_type_attribute`: >=20 > ``` > diff --git a/gcc/dwarf2out.c b/gcc/dwarf2out.c > index 89e52a41508..b0f6680bd61 100644 > --- a/gcc/dwarf2out.c > +++ b/gcc/dwarf2out.c > @@ -25709,6 +25709,9 @@ gen_type_die_with_usage (tree type, dw_die_ref > context_die, > static void > gen_type_die (tree type, dw_die_ref context_die) > { > + if (debug_info_level <=3D DINFO_LEVEL_TERSE) > + return; > + > if (type !=3D error_mark_node) > { > gen_type_die_with_usage (type, context_die, DINFO_USAGE_DIR_USE); > ``` >=20 > I verified that it makes the attached test case compile successfully. But then the static var is improperly scoped in the debug info? IMHO it's better left out.=