From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 3022 invoked by alias); 28 Apr 2006 21:13:07 -0000 Received: (qmail 3013 invoked by uid 22791); 28 Apr 2006 21:13:07 -0000 X-Spam-Check-By: sourceware.org Received: from nevyn.them.org (HELO nevyn.them.org) (66.93.172.17) by sourceware.org (qpsmtpd/0.31.1) with ESMTP; Fri, 28 Apr 2006 21:13:05 +0000 Received: from drow by nevyn.them.org with local (Exim 4.54) id 1FZaGo-0001kw-5Z; Fri, 28 Apr 2006 17:12:58 -0400 Date: Fri, 28 Apr 2006 21:13:00 -0000 From: Daniel Jacobowitz To: Mark Kettenis Cc: jimb@red-bean.com, brobecker@adacore.com, gdb-patches@sources.redhat.com Subject: Re: [RFC/RFA/i386] pb reading insns if breakpoints still inserted Message-ID: <20060428211258.GA6713@nevyn.them.org> Mail-Followup-To: Mark Kettenis , jimb@red-bean.com, brobecker@adacore.com, gdb-patches@sources.redhat.com References: <20060428171154.GP17613@adacore.com> <8f2776cb0604281054y116acfdavc3649dd8198d80d0@mail.gmail.com> <200604281839.k3SIdfsq030892@elgar.sibelius.xs4all.nl> <8f2776cb0604281358x2f667d00s90e03051f034b91c@mail.gmail.com> <200604282109.k3SL9Jwp020317@elgar.sibelius.xs4all.nl> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <200604282109.k3SL9Jwp020317@elgar.sibelius.xs4all.nl> User-Agent: Mutt/1.5.8i X-IsSubscribed: yes Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2006-04/txt/msg00375.txt.bz2 On Fri, Apr 28, 2006 at 11:09:19PM +0200, Mark Kettenis wrote: > But if we don't have debug information, what's the point in trying to > skip the prologue in order to put a breakpoint on ... eh what exactly? > Isn't it better to just punt prologue skipping in that case and place > the breakpoint on the first instruction of the code? Yes, I agree. I'd like to note, though, that the way we skip prologues based on debug information is completely wrong. It only works with GCC and with other compilers that have chosen to be bug-compatible with GCC. DWARF does support a "this is the end of the prologue" flag, but I don't know if GCC emits it, and I'm pretty positive GDB doesn't know how to consume it. [GCC just emits a line note before and after the prologue - even if they're on the same line.] -- Daniel Jacobowitz CodeSourcery