From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 1825 invoked by alias); 9 Oct 2003 12:42:10 -0000 Mailing-List: contact gcc-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-owner@gcc.gnu.org Received: (qmail 1817 invoked from network); 9 Oct 2003 12:42:10 -0000 Received: from unknown (HELO nevyn.them.org) (66.93.172.17) by sources.redhat.com with SMTP; 9 Oct 2003 12:42:10 -0000 Received: from drow by nevyn.them.org with local (Exim 4.22 #1 (Debian)) id 1A7a7M-0008I7-PV; Thu, 09 Oct 2003 08:42:08 -0400 Date: Thu, 09 Oct 2003 12:55:00 -0000 From: Daniel Jacobowitz To: Jakub Jelinek Cc: Alex Hornby , gcc@gcc.gnu.org Subject: Re: GCC, GDB v6 and -fomit-frame-pointer Message-ID: <20031009124208.GA31838@nevyn.them.org> Mail-Followup-To: Jakub Jelinek , Alex Hornby , gcc@gcc.gnu.org References: <3F852DBA.30401@anvil.com> <20031009123259.GA31546@nevyn.them.org> <20031009103608.GQ12344@sunsite.ms.mff.cuni.cz> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20031009103608.GQ12344@sunsite.ms.mff.cuni.cz> User-Agent: Mutt/1.5.1i X-SW-Source: 2003-10/txt/msg00328.txt.bz2 On Thu, Oct 09, 2003 at 12:36:08PM +0200, Jakub Jelinek wrote: > On Thu, Oct 09, 2003 at 08:33:00AM -0400, Daniel Jacobowitz wrote: > > On Thu, Oct 09, 2003 at 10:43:22AM +0100, Alex Hornby wrote: > > > > > > Does the new DWARF2 call frame in gdb 6.0 support mean programs compiled > > > with GCC and -fomit-frame-pointer can now be debugged? That would be > > > great as -fomit-frame-pointer provides quite a performance boost on x86. > > > > > > Assuming this is possible, what GCC and binutils versions would be > > > needed to take advantage of this? > > > > In general yes. Backtraces should work. Ultra-accurate argument and > > local variable printing requires -fvar-tracking in GCC so it's a little > > flaky now, but unwinding should be fine. > > > > Anything recent. I think 3.2, 3.3 are fine. > > Even without CFI info? With the exception of IA-64/AMD64, GCC doesn't > generate unwind info by default, only when -fasynchronous-unwind-tables. Sorry, unstated assumption. This only works if you build with debugging information. GDB parses both .eh_frame and .debug_frame, and all the necessary CFI should be in .debug_frame with -gdwarf-2. If debugging info bothers you, use objcopy --add-gnu-debuglink :) -- Daniel Jacobowitz MontaVista Software Debian GNU/Linux Developer