From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id BF80B3851C0E; Wed, 3 Jun 2020 06:03:43 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org BF80B3851C0E DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1591164223; bh=DINHiiJwOMhFUDHQJXQZ88tJizzkSSCtQ42leQgvha4=; h=From:To:Subject:Date:In-Reply-To:References:From; b=OJVHyYfMOof6uTysJrwtAoujo8O1PA1wzmpGGiZiz13RoNiv3K6ZHep1KUJ8kWvNw goMVfeW0avlZP0vLTilkVgbRplpJey0p27nsV8Z8TnzsS0X/flV+nzWathkNzot+gZ LIenEINbro9e8NKOxtP+tplewnfBgNv+PrDFD6xo= From: "rguenth at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug debug/95482] Feature request: add -gsplit-dwarf=single Date: Wed, 03 Jun 2020 06:03:43 +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: unknown X-Bugzilla-Keywords: X-Bugzilla-Severity: enhancement X-Bugzilla-Who: rguenth at gcc dot gnu.org X-Bugzilla-Status: UNCONFIRMED 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: bug_severity 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: Wed, 03 Jun 2020 06:03:43 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D95482 Richard Biener changed: What |Removed |Added ---------------------------------------------------------------------------- Severity|normal |enhancement --- Comment #1 from Richard Biener --- GCC does not by itself generate the separate .dwo file but instead the driv= er, after the assembler finished, runs objcopy via ASM_FINAL_SPEC: /* config.h can define ASM_FINAL_SPEC to run a post processor after the assembler has run. */ #ifndef ASM_FINAL_SPEC #define ASM_FINAL_SPEC \ "%{gsplit-dwarf: \n\ objcopy --extract-dwo \ %{c:%{o*:%*}%{!o*:%w%b%O}}%{!c:%U%O} \ %b.dwo \n\ objcopy --strip-dwo \ %{c:%{o*:%*}%{!o*:%w%b%O}}%{!c:%U%O} \ }" #endif so I would guess there's only small massaging necessary to get the desired functionality (the sections are already marked SHF_EXCLUDE). Patches welco= me, just figure out the correct magic to guard the SPEC above, like maybe "%{!gsplit-dwarf=3Dsingle: %{gsplit-dwarf: ... The choice of -gsplit-dwarf=3Dsingle is probably not too nice here though.=