From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 6CDB43858CDA; Sun, 25 Sep 2022 19:56:39 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 6CDB43858CDA DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1664135799; bh=hWGN7++W1nG/z/sogIMVuj0PqMkEFeLstcM3wgGldBY=; h=From:To:Subject:Date:In-Reply-To:References:From; b=cSOCZueo3iq8VJFiLYyJjgIeiIIjlY7+NfVuDxImqUXHEoHkoCIApujvhk35Fhr9s 6PYtcoml9IN08DXEReDbHTChnmvdrbAY1nZkenwIgUXIW7KUu1tpXWIkG8qKRGwlrm o1qMt9vLKEsC5EipXxpAez5mOGex58qLVUcSMB78= From: "andi-gcc at firstfloor dot org" To: gcc-bugs@gcc.gnu.org Subject: [Bug lto/107014] flatten+lto fails the kernel build Date: Sun, 25 Sep 2022 19:56:38 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: lto X-Bugzilla-Version: 12.1.1 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: andi-gcc at firstfloor dot org X-Bugzilla-Status: NEW X-Bugzilla-Resolution: X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- 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 List-Id: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D107014 Andi Kleen changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |andi-gcc at firstfloor dot= org --- Comment #9 from Andi Kleen --- I suspect what happens is that it hits in some kernel initialization functi= on. If they don't use initcall the LTO build can all inline them into each other (because they are only called once) creating a single big initialization function. With flatten that will create an extremely large function that ta= kes a long time to process. I suspect any use of flatten is better using always_inline, since that affe= cts only a single function. Should probably be fixed upstream in the kernel.=