From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 5438 invoked by alias); 20 May 2005 15:05:17 -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 4090 invoked from network); 20 May 2005 15:04:21 -0000 Received: from unknown (HELO ciao.gmane.org) (80.91.229.2) by sourceware.org with SMTP; 20 May 2005 15:04:21 -0000 Received: from root by ciao.gmane.org with local (Exim 4.43) id 1DZ8z7-0005cX-9D for gdb@sources.redhat.com; Fri, 20 May 2005 17:00:21 +0200 Received: from zigzag.lvk.cs.msu.su ([158.250.17.23]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri, 20 May 2005 17:00:21 +0200 Received: from ghost by zigzag.lvk.cs.msu.su with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri, 20 May 2005 17:00:21 +0200 To: gdb@sources.redhat.com From: Vladimir Prus Subject: Re: [discuss] Support for reverse-execution Date: Fri, 20 May 2005 15:05:00 -0000 Message-ID: References: <00c601c55747$860a3e80$aaa56b80@msnyder8600> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7Bit User-Agent: KNode/0.8.2 X-SW-Source: 2005-05/txt/msg00221.txt.bz2 Michael Snyder wrote: > I'd like to start adding some commands to gdb to support targets > that can perform reverse execution (eg. stepping backwards). > This concept has been around for a number of years now, and I > have access to a target (the Simics simulator from Virtutech) > that does it quite handily. > > I propose we add something like the following commands > (names open to discussion): > > reverse-continue -- start executing backwards until something > interesting happens (most likely hitting a breakpoint). > > reverse-stepi -- "un-execute" the previous instruction. > > reverse-step -- "un-execute" the previous source line. > > reverse-finish or "un-call" -- proceed backward until > the current function is about to be called by its caller. > > reverse-until... etc. Would not it be better to have a single "reverse" command which puts the debugger in "reverse" mode -- making step/stepi/next/nexti go backward. This might be handier for UI -- after all "step" can be abbreviated as 's', but reverse-step can't be abbreviated. This might be better in GUI too -- instead of doubling the number of "step" commands you'd have a single "gear" switch, that can be in either "forward" or "reverse" position. - Volodya