From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 25586 invoked by alias); 24 Apr 2006 20:47:12 -0000 Received: (qmail 25571 invoked by uid 22791); 24 Apr 2006 20:47:11 -0000 X-Spam-Check-By: sourceware.org Received: from nevyn.them.org (HELO nevyn.them.org) (66.93.172.17) by sourceware.org (qpsmtpd/0.31.1) with ESMTP; Mon, 24 Apr 2006 20:47:09 +0000 Received: from drow by nevyn.them.org with local (Exim 4.54) id 1FY7xZ-0000dR-90; Mon, 24 Apr 2006 16:47:05 -0400 Date: Mon, 24 Apr 2006 20:47:00 -0000 From: Daniel Jacobowitz To: Michael Snyder Cc: Eli Zaretskii , gdb-patches@sources.redhat.com Subject: Re: [RFA] Reverse debugging, part 3/3: user interface / docs Message-ID: <20060424204705.GA27220@nevyn.them.org> Mail-Followup-To: Michael Snyder , Eli Zaretskii , gdb-patches@sources.redhat.com References: <442DAAD9.6080509@redhat.com> <44442877.1060401@redhat.com> <20060420160717.GF11710@nevyn.them.org> <44481117.8070904@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <44481117.8070904@redhat.com> User-Agent: Mutt/1.5.8i X-IsSubscribed: yes Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2006-04/txt/msg00323.txt.bz2 On Thu, Apr 20, 2006 at 03:54:15PM -0700, Michael Snyder wrote: > Daniel Jacobowitz wrote: > > > >FWIW, I've got no opinions on this patch. The content looks fine. My > >only concern is that I don't much like "set" variables which succeed or > >fail depending on the target - we can switch targets unexpectedly. > > > >Can we just give the error in proceed if the target can't run in > >reverse? > > You mean, "and not give an error when you say "set exec-dir"? > > Well here's the thing: I've had experience with something > very similar*, and the users complained. They wanted to > know sooner if there was a problem. > > * Tracepoints. You don't find out that the remote target can't > support them until you say continue. Sorry about the delay; I started replying to this on Thursday but didn't finish it before I headed out for a long weekend. I agree that, as user interface, this is unpleasant. But here's some of the other cases we have to consider. (gdb) set exec-dir reverse (gdb) target remote :1234 -> Should it work before you're connected? (gdb) target remote :1234 (gdb) set exec-dir reverse (gdb) disconnect (gdb) run -> Where do we get the error now? We've switched targets, "run" can't go in reverse for target child. And as we've already seen, your error doesn't actually come at the right time, since your remote protocol doesn't have a probe packet! So remote will always let it succeed and child will always make it fail, regardless of whether the remote target actually supports it. That's mighty inconsistent. I'm open to suggestions on a more consistent way to present the problem. -- Daniel Jacobowitz CodeSourcery