From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 14283 invoked by alias); 16 Dec 2002 18:20:07 -0000 Mailing-List: contact gdb-patches-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sources.redhat.com Received: (qmail 14234 invoked from network); 16 Dec 2002 18:20:04 -0000 Received: from unknown (HELO mx1.redhat.com) (66.187.233.31) by sources.redhat.com with SMTP; 16 Dec 2002 18:20:04 -0000 Received: from int-mx1.corp.redhat.com (int-mx1.corp.redhat.com [172.16.52.254]) by mx1.redhat.com (8.11.6/8.11.6) with ESMTP id gBGHs2g15046 for ; Mon, 16 Dec 2002 12:54:02 -0500 Received: from pobox.corp.redhat.com (pobox.corp.redhat.com [172.16.52.156]) by int-mx1.corp.redhat.com (8.11.6/8.11.6) with ESMTP id gBGIK3226242; Mon, 16 Dec 2002 13:20:03 -0500 Received: from localhost.redhat.com (romulus-int.sfbay.redhat.com [172.16.27.46]) by pobox.corp.redhat.com (8.11.6/8.11.6) with ESMTP id gBGIK0M15346; Mon, 16 Dec 2002 13:20:01 -0500 Received: by localhost.redhat.com (Postfix, from userid 469) id 4F500FF79; Mon, 16 Dec 2002 13:24:29 -0500 (EST) From: Elena Zannoni MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Message-ID: <15870.6748.994104.390618@localhost.redhat.com> Date: Mon, 16 Dec 2002 10:22:00 -0000 To: "J. Johnston" Cc: Daniel Jacobowitz , gdb-patches@sources.redhat.com, ezannoni@redhat.com Subject: Re: Recent MI patches broke the testsuite In-Reply-To: <3DFE15BA.4080207@redhat.com> References: <20021215211132.GA31984@nevyn.them.org> <3DFE15BA.4080207@redhat.com> X-SW-Source: 2002-12/txt/msg00490.txt.bz2 J. Johnston writes: > My bad. :( The new mi-basics.exp testcase is my usual sanity test > for this change. It was updated and in fact works fine as it is expecting > the new behavior. > > I did not look at the correct gdb.log for the full mi testsuite. > As you have noted, the lib/mi-support.exp routine mi_reinitialize_dir > is using -environment-directory and is expecting the old output. > > I have a patch for lib/mi=support.exp to handle the new syntax which I have > included. Since I require approval for patches I will revert the > original patch and resubmit with the added change unless Elena says > otherwise. > If this patch fixes the testsuite, no need to revert the other one, just check this in. Don't forget the ChangeLog. Maybe Daniel can verify that it fixes his problem? Elena > -- Jeff J. > > Daniel Jacobowitz wrote: > > 202-environment-directory ../../../src/gdb/testsuite/gdb.mi > > 202^done,source-path="/opt/src/binutils/x86-as/gdb/testsuite/../../../src/gdb/testsuite/gdb.mi:$cdir:$cwd" > > (gdb) > > FAIL: gdb.mi/mi-basics.exp: environment-directory arg operation > > 203-environment-directory > > 203^done,source-path="/opt/src/binutils/x86-as/gdb/testsuite/../../../src/gdb/testsuite/gdb.mi:$cdir:$cwd" > > (gdb) > > FAIL: gdb.mi/mi-basics.exp: environment-directory empty-string operation > > > > It appears to be this patch: > > 2002-12-13 Jeff Johnston > > > > * mi-cmds.c (-environment-directory) Change to use mi_cmd_env_dir, > > (-environment-cd): Change to use mi_cmd_env_cd,. > > (-environment-pwd): Change to use mi_cmd_env_pwd. > > (-environment-path): Change to use mi_cmd_env_path. > > * mi-cmds.h (mi_cmd_env_cd, mi_cmd_env_dir): New prototypes. > > (mi_cmd_env_path, mi_cmd_env_pwd): Ditto. > > * mi-cmd-env.c: New file. Part of fix for PR gdb/741. > > * gdbmi.texinfo (environment-cd): Update output and example. > > (environment-pwd): Ditto. > > (environment-dir): Update output, description, and examples. > > (environment-path): Ditto. > > > > > > Not only did it break several tests in gdb.mi/, it also broke the utility > > function mi_gdb_reinitialize_dir in lib/mi-support.exp. This causes all my > > testsuite runs to time out. Please don't commit patches like this without > > testing them. > > > > The output which expects "105-^done\r\n" needs to be updated as well as the > > tests in mi-basics.exp; possibly elsewhere. > > > > Index: lib/mi-support.exp > =================================================================== > RCS file: /cvs/src/src/gdb/testsuite/lib/mi-support.exp,v > retrieving revision 1.19 > diff -u -r1.19 mi-support.exp > --- lib/mi-support.exp 25 Nov 2002 19:54:09 -0000 1.19 > +++ lib/mi-support.exp 16 Dec 2002 17:49:08 -0000 > @@ -234,6 +234,7 @@ > > proc mi_gdb_reinitialize_dir { subdir } { > global mi_gdb_prompt > + global MIFLAGS > > global suppress_flag > if { $suppress_flag } { > @@ -244,8 +245,9 @@ > return ""; > } > > - send_gdb "104-environment-directory\n" > - gdb_expect 60 { > + if { $MIFLAGS == "-i=mi1" } { > + send_gdb "104-environment-directory\n" > + gdb_expect 60 { > -re ".*Reinitialize source path to empty.*y or n. " { > warning "Got confirmation prompt for dir reinitialization." > send_gdb "y\n" > @@ -256,6 +258,14 @@ > } > -re "$mi_gdb_prompt$" {} > timeout {error "Dir reinitialization failed (timeout)"} > + } > + } else { > + send_gdb "104-environment-directory -r\n" > + gdb_expect 60 { > + -re "104\\\^done,source-path=.*\r\n$mi_gdb_prompt$" {} > + -re "$mi_gdb_prompt$" {} > + timeout {error "Dir reinitialization failed (timeout)"} > + } > } > > send_gdb "105-environment-directory $subdir\n" > @@ -263,7 +273,7 @@ > -re "Source directories searched.*$mi_gdb_prompt$" { > verbose "Dir set to $subdir" > } > - -re "105\\\^done\r\n$mi_gdb_prompt$" { > + -re "105\\\^done.*\r\n$mi_gdb_prompt$" { > # FIXME: We return just the prompt for now. > verbose "Dir set to $subdir" > # perror "Dir \"$subdir\" failed."