From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 2030 invoked by alias); 30 Jan 2013 13:40:09 -0000 Received: (qmail 32643 invoked by uid 48); 30 Jan 2013 13:39:41 -0000 From: "d.g.gorbachev at gmail dot com" To: gcc-bugs@gcc.gnu.org Subject: [Bug lto/56061] [4.8 Regression] ICE in lto1 (in inline_call, at ipa-inline-transform.c:267) Date: Wed, 30 Jan 2013 13:40:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: lto X-Bugzilla-Keywords: ice-on-valid-code, lto X-Bugzilla-Severity: normal X-Bugzilla-Who: d.g.gorbachev at gmail dot com X-Bugzilla-Status: NEW X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: 4.8.0 X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated Content-Type: text/plain; charset="UTF-8" MIME-Version: 1.0 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org X-SW-Source: 2013-01/txt/msg02747.txt.bz2 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=56061 --- Comment #7 from Dmitry Gorbachev 2013-01-30 13:39:37 UTC --- > The other way around, compiling and installing with > -O2 but then at link time use -O0 -g to get a debug > build is more questionable > However, I still don't see the point of "-O0 -flto" > at link-time. We should either force it to be at > least -O1 or (in my opinion better) give an error. I think it could make sense. For example, I compile a certain static library with `-O3 -flto', without `-g' (it's considered already debugged) and without `-fno-fat-lto-objects' (so it can be used either with or without LTO); it is shared between several programs. The programs have their own static libs, which are compiled with `-g -O1 -flto -fno-fat-lto-objects' (could be `-O0', but doesn't work, PR55102). Then, they are linked using `-g -O0 -flto' to get a (partially) debug enabled program, or with `-O3 -flto' for a fully optimized program. > the docs have this example Yes, but there is an aforementioned bug 55102.