From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id E0CA23857712; Fri, 6 Oct 2023 22:03:10 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org E0CA23857712 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1696629790; bh=U9BL16+8Dq+PiT9QLmxFrLVf0uefLNpxOa7ToOxquJ4=; h=From:To:Subject:Date:In-Reply-To:References:From; b=xNiFTnuCJX/cyH6Bh3aI95WzS/aIkvO0tSa5jLWHOgZq5WtEjS7W4hTBvgO1zc9jT mde5q0hLQZrq4ToXl2HkOCfM+t4jSGF/BtCyZqrj7LFyRyAHMHmhY9PNr0c2UxR/Ms daPKZYVG5oz1+p0hbxYYiwKTo+m8ZEFEMDDGuHTE= From: "lukas.graetz@tu-darmstadt.de" To: gcc-bugs@gcc.gnu.org Subject: [Bug ipa/111643] __attribute__((flatten)) with -O1 runs out of memory (killed cc1) Date: Fri, 06 Oct 2023 22:03:10 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: ipa X-Bugzilla-Version: 13.2.0 X-Bugzilla-Keywords: documentation X-Bugzilla-Severity: normal X-Bugzilla-Who: lukas.graetz@tu-darmstadt.de X-Bugzilla-Status: RESOLVED X-Bugzilla-Resolution: WONTFIX 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: 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=3D111643 --- Comment #14 from Lukas Gr=C3=A4tz --- (In reply to Andrew Pinski from comment #13) > (In reply to Andrew Pinski from comment #12) > > Gcc does have tail call optimization which should allow the instrumenta= tion > > with less overhead. Though tail call optimization happens at -O2 and ab= ove > > only (by default). >=20 > The only improvement to this would be fall through alias which allows the > removal of the jump to the other function. A direct non-conditional jump = is > usually predictable so the overhead should be small still. Thanks! I thought that there was still some stack involved also causing some overhead for every function call (in comparison to a pure non-conditional jump). When I have time next week, I will try to look into that in detail.=