From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 20743 invoked by alias); 16 Jul 2009 15:55:57 -0000 Received: (qmail 20733 invoked by uid 22791); 16 Jul 2009 15:55:56 -0000 X-SWARE-Spam-Status: No, hits=-2.3 required=5.0 tests=AWL,BAYES_00,SPF_PASS X-Spam-Check-By: sourceware.org Received: from imr1.ericy.com (HELO imr1.ericy.com) (198.24.6.9) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Thu, 16 Jul 2009 15:55:49 +0000 Received: from eusrcmw750.eamcs.ericsson.se (eusrcmw750.exu.ericsson.se [138.85.77.50]) by imr1.ericy.com (8.13.1/8.13.1) with ESMTP id n6GFth5o025361; Thu, 16 Jul 2009 10:55:43 -0500 Received: from ecamlmw720.eamcs.ericsson.se ([142.133.1.72]) by eusrcmw750.eamcs.ericsson.se with Microsoft SMTPSVC(6.0.3790.1830); Thu, 16 Jul 2009 10:55:06 -0500 Content-class: urn:content-classes:message MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Subject: RE: Reverse debugging Date: Thu, 16 Jul 2009 15:55:00 -0000 Message-ID: <6D19CA8D71C89C43A057926FE0D4ADAA07BD6DD6@ecamlmw720.eamcs.ericsson.se> In-Reply-To: References: <19035.54231.157231.624882@totara.tehura.co.nz> <4A5BD5F3.1090103@vmware.com> <19035.57129.173542.368393@totara.tehura.co.nz> <4A5CC0E1.7020800@vmware.com> <19037.16041.589932.535743@totara.tehura.co.nz> From: "Marc Khouzam" To: "Hui Zhu" , "Nick Roberts" Cc: , "Michael Snyder" 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: 2009-07/txt/msg00102.txt.bz2 > -----Original Message----- > From: Hui Zhu [mailto:teawater@gmail.com]=20 > Sent: July-15-09 11:09 PM > To: Nick Roberts; Marc Khouzam > Cc: gdb@sources.redhat.com; Michael Snyder > Subject: Re: Reverse debugging >=20 > Thanks Nick, I think the better way is add a special cmd for it. >=20 > Marc, do you have some ideas with it? >=20 >=20 > Thanks, > Hui >=20 > On Wed, Jul 15, 2009 at 10:27, Nick=20 > Roberts wrote: > > I've created tool bar functionality in Emacs for reverse=20 > debugging a bit like > > that in the DSF-GDB debugger for Eclipse, I think. Cool! > > > > It works quite nicely and I would like to include it in=20 > Emacs 23.2 (23.1 > > should be coming out next week) but there is one small=20 > problem with "record > > stop". =A0It currently prompts the user for confirmation and=20 > Emacs can't handle > > that from the tool bar and update the GUI. =A0Would it be=20 > possible to add a > > "noconfirm" option, perhaps like below, which should be=20 > invisible to the > > normal user? So in your case you are dealing with a proper tty? For eclipse, we fall in the !from_tty case. Frontends should definetely not be bothered with those queries. In my mind, a FE should know what it is doing so if it requests an action like 'record stop' it should not be prompted at all. This is probably true for any of these queries. I was originally going to ask Hui always have a !from_tty check, but now it seems this would not work for emacs. Can we check if the default interpreter is MI somehow and in those cases not do the query? The idea is that if one uses MI then it is not in some user-interactive session. Just a thought... Marc > > > > -- > > Nick =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 = =A0 =A0 =A0 =A0 =A0=20 > http://www.inet.net.nz/~nickrob > > > > > > 2009-07-15 =A0Nick Roberts =A0 > > > > =A0 =A0 =A0 =A0* record.c (cmd_record_stop): Add a "noconfirm" option t= o the > > =A0 =A0 =A0 =A0"record stop" command. > > > > > > Index: record.c > > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > > RCS file: /cvs/src/src/gdb/record.c,v > > retrieving revision 1.8 > > diff -c -p -r1.8 record.c > > *** record.c =A0 =A02 Jul 2009 17:21:06 -0000 =A0 =A0 =A0 1.8 > > --- record.c =A0 =A015 Jul 2009 02:25:21 -0000 > > *************** cmd_record_stop (char *args, int from_tt > > *** 1157,1164 **** > > =A0{ > > =A0 =A0if (current_target.to_stratum =3D=3D record_stratum) > > =A0 =A0 =A0{ > > ! =A0 =A0 =A0 if (!record_list || !from_tty || query (_("Delete=20 > recorded log and " > > ! =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 = =A0 =A0 =A0 =A0 =A0 =A0 "stop recording?"))) > > =A0 =A0 =A0 =A0unpush_target (&record_ops); > > =A0 =A0 =A0} > > =A0 =A0else > > --- 1157,1168 ---- > > =A0{ > > =A0 =A0if (current_target.to_stratum =3D=3D record_stratum) > > =A0 =A0 =A0{ > > ! =A0 =A0 =A0 int noconfirm =3D 0; > > ! =A0 =A0 =A0 if (args) > > ! =A0 =A0 =A0 =A0 noconfirm =3D (strcmp (args, "noconfirm") =3D=3D 0) ?= 1 : 0; > > ! > > ! =A0 =A0 =A0 if (!record_list || !from_tty || noconfirm > > ! =A0 =A0 =A0 =A0 || query (_("Delete recorded log and stop recording?"= ))) > > =A0 =A0 =A0 =A0unpush_target (&record_ops); > > =A0 =A0 =A0} > > =A0 =A0else > > >=20