From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 30254 invoked by alias); 23 Aug 2004 18:48:05 -0000 Mailing-List: contact gdb-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sources.redhat.com Received: (qmail 30224 invoked from network); 23 Aug 2004 18:48:04 -0000 Received: from unknown (HELO nevyn.them.org) (66.93.172.17) by sourceware.org with SMTP; 23 Aug 2004 18:48:04 -0000 Received: from drow by nevyn.them.org with local (Exim 4.34 #1 (Debian)) id 1BzJrO-0002ng-0V; Mon, 23 Aug 2004 14:48:02 -0400 Date: Mon, 23 Aug 2004 18:48:00 -0000 From: Daniel Jacobowitz To: David Daney Cc: Andrew Cagney , gdb@sources.redhat.com Subject: Re: Unable to step over (n and ni) on mipsel-linux... Message-ID: <20040823184801.GA10657@nevyn.them.org> Mail-Followup-To: David Daney , Andrew Cagney , gdb@sources.redhat.com References: <412649F4.9040002@avtrex.com> <412A25B1.7080308@gnu.org> <412A30E5.9080809@avtrex.com> <412A3672.5040904@gnu.org> <412A39AF.1080103@avtrex.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <412A39AF.1080103@avtrex.com> User-Agent: Mutt/1.5.5.1+cvs20040105i X-SW-Source: 2004-08/txt/msg00289.txt.bz2 On Mon, Aug 23, 2004 at 11:38:39AM -0700, David Daney wrote: > Andrew Cagney wrote: > >> > >>Currently GDB examines the next instruction to see if it is a branch (or > >> jal or jalr..) to see where to place a temporary breakpoint for single > >>stepping. > > > > > >>Instead of stepping into a function and checking to see if we are in a > >>different frame (settting a breakpoint at the return address location), > >>why not set the breakpoint at the return location before making the > >>function call? > > > > > > That would mean examining every instruction to determine if it is a call > > - effectively s/w single step. GDB tries to do avoid doing that so that > > single-step is faster. > > > > For my configuration, for some reason it is already doing this. Thus my > comment. If we are doing s/w single step, we would not have to examine > the stack frames. > > Could there are some configuration problems? GDB already does this on all MIPS targets. > This implies that if I write assembly language I cannot expect GDB's ni > instruction to work. It should work OK. You have to have some stack frame anyway, and GDB has a prologue analyzer. > I am doing testing with at least three different compiler versions. GDB > 5.3 seems to work well except for crashing when I don't use > -fno-var-tracking. > > GDB 6.x seems to be a bit of a down-grade. GDB 6.2 and MIPS do not get along very well. I ran out of time to work on the MIPS unwinder, but Joel and others have done some work, and I hope to get back to testing it sometime. -- Daniel Jacobowitz