From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 14548 invoked by alias); 29 Apr 2009 18:39:58 -0000 Received: (qmail 14540 invoked by uid 22791); 29 Apr 2009 18:39:57 -0000 X-SWARE-Spam-Status: No, hits=-2.5 required=5.0 tests=AWL,BAYES_00 X-Spam-Check-By: sourceware.org Received: from NaN.false.org (HELO nan.false.org) (208.75.86.248) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Wed, 29 Apr 2009 18:39:51 +0000 Received: from nan.false.org (localhost [127.0.0.1]) by nan.false.org (Postfix) with ESMTP id EE50210738; Wed, 29 Apr 2009 18:39:47 +0000 (GMT) Received: from caradoc.them.org (209.195.188.212.nauticom.net [209.195.188.212]) by nan.false.org (Postfix) with ESMTP id CA4D110554; Wed, 29 Apr 2009 18:39:47 +0000 (GMT) Received: from drow by caradoc.them.org with local (Exim 4.69) (envelope-from ) id 1LzEh8-0007L7-C3; Wed, 29 Apr 2009 14:39:46 -0400 Date: Wed, 29 Apr 2009 18:54:00 -0000 From: Daniel Jacobowitz To: Eli Zaretskii Cc: gdb@sourceware.org Subject: Re: Debugging a frameless function Message-ID: <20090429183946.GA28155@caradoc.them.org> Mail-Followup-To: Eli Zaretskii , gdb@sourceware.org References: <83zldzco0p.fsf@gnu.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <83zldzco0p.fsf@gnu.org> User-Agent: Mutt/1.5.17 (2008-05-11) X-IsSubscribed: yes Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org X-SW-Source: 2009-04/txt/msg00217.txt.bz2 On Wed, Apr 29, 2009 at 09:28:54PM +0300, Eli Zaretskii wrote: > My question is, how should GDB overcome the difficulty of a frameless > function, when it tries to unwind a frame where EBP is used for > holding a variable? Can someone please spot any missing pieces in the > session below, and give me hints on where to look for the source of > the trouble? Sounds like the debug info is bad. If it tells GDB to look for something relative to the frame base, and it tells GDB that the frame base is in %ebp, but %ebp has a random variable, then the debug info is incorrect. Check manually, using readelf -wi (and -wo if location lists are in use). -- Daniel Jacobowitz CodeSourcery