From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 3483 invoked by alias); 5 Feb 2003 13:59:57 -0000 Mailing-List: contact gdb-patches-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sources.redhat.com Received: (qmail 3476 invoked from network); 5 Feb 2003 13:59:56 -0000 Received: from unknown (HELO crack.them.org) (65.125.64.184) by 172.16.49.205 with SMTP; 5 Feb 2003 13:59:56 -0000 Received: from nevyn.them.org ([66.93.61.169] ident=mail) by crack.them.org with asmtp (Exim 3.12 #1 (Debian)) id 18gRyb-000257-00; Wed, 05 Feb 2003 10:00:41 -0600 Received: from drow by nevyn.them.org with local (Exim 3.36 #1 (Debian)) id 18gQ5b-0007x2-00; Wed, 05 Feb 2003 08:59:47 -0500 Date: Wed, 05 Feb 2003 13:59:00 -0000 From: Daniel Jacobowitz To: Jason Molenda Cc: David Carlton , Andrew Cagney , gdb-patches@sources.redhat.com, jjohnstn@redhat.com Subject: Re: PATCH RFA: Fix MI stack frame output for synthetic frames Message-ID: <20030205135947.GA30516@nevyn.them.org> Mail-Followup-To: Jason Molenda , David Carlton , Andrew Cagney , gdb-patches@sources.redhat.com, jjohnstn@redhat.com References: <20021108142248.A65720@molenda.com> <3DCC3CEE.5040902@redhat.com> <20021109004723.A20334@molenda.com> <3E3CB218.1020706@redhat.com> <20030203102748.A75701@molenda.com> <20030203183441.GA27429@nevyn.them.org> <20030204000936.A19984@molenda.com> <20030205002416.A75501@molenda.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20030205002416.A75501@molenda.com> User-Agent: Mutt/1.5.1i X-SW-Source: 2003-02/txt/msg00182.txt.bz2 On Wed, Feb 05, 2003 at 12:24:16AM -0800, Jason Molenda wrote: > gcc 3.2 is outputting debug info like this - > > .stabs "subroutine:F(9,7)",36,0,0,subroutine > .stabs "in:p(0,1)",160,0,0,8 > .globl subroutine > .type subroutine,@function > subroutine: > .stabn 68,0,48,.LM18-subroutine > .LM18: > pushl %ebp > movl %esp, %ebp > nop > .stabn 68,0,49,.LM19-subroutine ; line #49 is the while (...) > .LM19: > .L6: > cmpl $99, 8(%ebp) > jle .L8 > jmp .L5 > .L8: > > The compiler is correct to put the line stab there (it does the > equivalent for DWARF2), and gdb is correct in putting the breakpoint > on the cmpl insn, but the unfortunate end result of these two is that > a user putting a breakpoint on the subroutine will have a breakpoint > that's tripped each iteration of the loop. > > Given all that, I'll check in a change to mi-syn-frames.c so this > function reads > > void > subroutine (int in) > { > int count = in; > while (count < 100) > count++; > } > > The assignment gives us two assembly instructions after the end of the > prologue for a breakpoint that won't be hit at each iteration. It's > stupid, I know. > > I'll make that change and run it through the testsuites tomorrow > night. If I get approval for the change before then (hint hint :) > I'll check it in, else I'll post a patch. Pre-approved as an obvious fix to the test. Thanks for following up. I think there are a few other failures; I'll check again after you've fixed this one. -- Daniel Jacobowitz MontaVista Software Debian GNU/Linux Developer