From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 19863 invoked by alias); 14 Feb 2003 16:34:13 -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 19856 invoked from network); 14 Feb 2003 16:34:13 -0000 Received: from unknown (HELO crack.them.org) (65.125.64.184) by 172.16.49.205 with SMTP; 14 Feb 2003 16:34:13 -0000 Received: from nevyn.them.org ([66.93.61.169] ident=mail) by crack.them.org with asmtp (Exim 3.12 #1 (Debian)) id 18jkg4-0000TR-00; Fri, 14 Feb 2003 12:35:12 -0600 Received: from drow by nevyn.them.org with local (Exim 3.36 #1 (Debian)) id 18jimu-0001x5-00; Fri, 14 Feb 2003 11:34:08 -0500 Date: Fri, 14 Feb 2003 16:34:00 -0000 From: Daniel Jacobowitz To: Jan Hoogerbrugge Cc: msalter@redhat.com, ac131313@redhat.com, gdb@sources.redhat.com Subject: Re: Remote breakpoint problem Message-ID: <20030214163408.GA7487@nevyn.them.org> Mail-Followup-To: Jan Hoogerbrugge , msalter@redhat.com, ac131313@redhat.com, gdb@sources.redhat.com References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.1i X-SW-Source: 2003-02/txt/msg00240.txt.bz2 On Fri, Feb 14, 2003 at 05:28:43PM +0100, Jan Hoogerbrugge wrote: > >From: Mark Salter > >To: ac131313@redhat.com > >>>>>> Andrew Cagney writes: > > > >>> Hi, > >>> > >>> I am porting gdb to a new target processor were remote debugging is > >used. I have a problem with breakpoints. When I place a breakpoint on foo > >followed by a continue I see the following communication between gdb and > >the stub on the other side: > >>> > >>> - the instruction at foo is saved > >>> - foo is replaced by a breakpoint instruction > >>> - gdb sends a continue command > >>> - the stub reports the breakpoint hit (signal = 5, pc = foo) > >>> - gdb replaces the code at foo with the saved instruction > >>> - gdb sends a step instruction command > >>> - tbe stub reports again a breakpoint hit at foo (signal = 5, pc = foo) > > > >> Shouldn't this stop beyond foo? > > > >I wonder if the stub is flushing the icache after gdb puts the > >saved instruction back... > > Caches are properly syncronisched. The respone of the remote target and its > stub is correct as far as I can see. It is gdb that issues a continue > command to the stub after hitting the breakpoint and single stepping the > instruction on which teh breakpoint was placed. If you single-step over the instruction at foo, and the stub reports a stop at foo, something is wrong. You're stopped at the _following_ instruction. -- Daniel Jacobowitz MontaVista Software Debian GNU/Linux Developer