From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 7276 invoked by alias); 10 Aug 2007 18:18:24 -0000 Received: (qmail 6920 invoked by uid 22791); 10 Aug 2007 18:18:23 -0000 X-Spam-Check-By: sourceware.org Received: from NaN.false.org (HELO nan.false.org) (208.75.86.248) by sourceware.org (qpsmtpd/0.31) with ESMTP; Fri, 10 Aug 2007 18:18:20 +0000 Received: from nan.false.org (localhost [127.0.0.1]) by nan.false.org (Postfix) with ESMTP id 72CE6982CF; Fri, 10 Aug 2007 18:18:20 +0000 (GMT) Received: from caradoc.them.org (22.svnf5.xdsl.nauticom.net [209.195.183.55]) by nan.false.org (Postfix) with ESMTP id 32B4D982CE; Fri, 10 Aug 2007 18:18:20 +0000 (GMT) Received: from drow by caradoc.them.org with local (Exim 4.67) (envelope-from ) id 1IJZ3x-000356-UD; Fri, 10 Aug 2007 14:18:17 -0400 Date: Fri, 10 Aug 2007 18:18:00 -0000 From: Daniel Jacobowitz To: teawater Cc: gdb@sources.redhat.com Subject: Re: GDB record target 0.0.1 for GDB-6.6 release (It make GDB support Reversible Debugging) Message-ID: <20070810181817.GA11548@caradoc.them.org> Mail-Followup-To: teawater , 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.15 (2007-04-09) X-IsSubscribed: yes Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org X-SW-Source: 2007-08/txt/msg00102.txt.bz2 On Fri, Aug 10, 2007 at 05:31:51PM +0800, teawater wrote: > Hi All, > > The attachment is a patch for the GDB-6.6 that will add two commands > ("record" and "reverse") and a new target "record" to the GDB-6.6. > > The command "record" can record running message such as the program pc > register value and some frame message to a record file that default > name is "now.rec". > > The target "record" can open this record file and debug the program. > And if the current target is the "record", you can use command > "reverse" set debug to the reverse debug mode. If you set GDB to the > reverse debug mode. The program will reverse run. Most of GDB command > such as "step", "next" and "breakpoint" can be use in this mode. > > Maybe the record function can make GDB debug real time program more > easy than before because you can record all the running message when > the real time program cannot be interrupt and debug it after it was > running. I took a look at your patch. The record command single steps the program until it exits, right? That will not be very useful for real time programs, because it will be extraordinarily slow the first time. You might want to take a look at my paper in this year's GCC Summit proceedings: http://gcc.gnu.org/wiki/HomePage?action=AttachFile&do=get&target=GCC2007-Proceedings.pdf We'll be publishing the code for "reverse-step" using qemu soon. We're not trying to hold on to it, especially - just haven't found the time yet to submit it. This is basically similar to what you've done, except higher performance. Actually, your work also reminds me of Amber: http://weblogs.mozillazine.org/roc/archives/2006/12/more_about_ambe.html -- Daniel Jacobowitz CodeSourcery