From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 9683 invoked by alias); 24 Sep 2003 12:25:37 -0000 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org Received: (qmail 9675 invoked by uid 48); 24 Sep 2003 12:25:37 -0000 Date: Wed, 24 Sep 2003 18:09:00 -0000 From: "rsandifo at gcc dot gnu dot org" To: gcc-bugs@gcc.gnu.org Message-ID: <20030924122533.12389.rsandifo@gcc.gnu.org> Reply-To: gcc-bugzilla@gcc.gnu.org Subject: [Bug debug/12389] New: ICE in gen_subprogram_die for nested function X-Bugzilla-Reason: CC X-SW-Source: 2003-09/txt/msg01858.txt.bz2 List-Id: PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org. http://gcc.gnu.org/bugzilla/show_bug.cgi?id=12389 Summary: ICE in gen_subprogram_die for nested function Product: gcc Version: 3.4 Status: UNCONFIRMED Severity: normal Priority: P2 Component: debug AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: rsandifo at gcc dot gnu dot org CC: gcc-bugs at gcc dot gnu dot org,rsandifo at gcc dot gnu dot org GCC target triplet: i686-pc-linux-gnu Sorry if this already a known problem! I tried searching for it but couldn't find anything. The following test case: int f1 (int y) { int f2() { return y; } return f2(); } causes an ICE on i686-pc-linux-gnu if compiled with -O2 -g: /tmp/foo.c: In function `f2': /tmp/foo.c:5: internal compiler error: in gen_subprogram_die, at dwarf2out.c:10614 Please submit a full bug report, with preprocessed source if appropriate. See for instructions. It works OK if compiled with -O3 -g or with -O2 -fno-unit-at-a-time -g. At a guess, I think that dwarf code is getting confused by the inlining of functions that aren't marked !DECL_INLINE. It'll be a few days before I can look into much more though.