Remove all mentions of mips-idt. (was: Re: [05/10] watchpoint.exp: Clean up "mips-idt-*" specific re-initialization.)

Pedro Alves palves@redhat.com
Thu Feb 2 15:25:00 GMT 2012


On 02/02/2012 02:05 PM, Pedro Alves wrote:
> On 01/30/2012 08:14 PM, Stan Shebs wrote:
>> On 1/26/12 6:19 AM, Pedro Alves wrote:
>>> I don't know if there's still anyone who cares about mips-idt.  This cleans that
>>> target's specific re-initialization hacks, by doing them close to where a test
>>> starts running the program from scratch.
>>>
>>> If mips-idt is completely dead, we could instead get rid of all this stuff (it was
>>> introduced in 1993), which exists in several tests.
>>>
>>
>> IDT still claims to be selling the MIPS chips, but it's not so clear about the boards that the mips-idt config targets.  Their site has board manuals dated as recently as 2006.
> 
> Thanks.
> 
>> Perhaps this would be a good candidate for official deprecation in 7.5 - I certainly wouldn't miss the funkiness that is remote-mips.c ... :-)
> 
> Indeed, though I think remote-mips.c still has users (but for mips-elf only).  Kevin brought it back from the dead not so long ago.
> 
> This made me go do some archaeology.  I noticed that:
> 
> - mips-idt really means mips-idt-ecoff.
> - By gdb 4.12, mips-idt-ecoff selected the "idt" target -> config/mips/idt.mt
> - By gdb 5.0,  mips-idt-ecoff selected the "embed" target -> config/mips/embed.mt  (which reads: # Target: Big-endian mips board, typically an IDT.)
> 
> So the idt target turned into a somewhat more generic embed target.
> 
> - In http://sourceware.org/ml/gdb-patches/2004-11/msg00300.html
> 
> 2004-11-13  Andrew Cagney  <cagney@gnu.org>
> 
> 	* regcache.h (deprecated_register_valid): Delete.
> 	(deprecated_registers): Delete.
> 	* regcache.c (deprecated_register_valid): Delete.
> 	(deprecated_registers): Delete.
> 	(deprecated_read_register_byte, _initialize_regcache)
> 	(deprecated_write_register_bytes, build_regcache): Update.
> 	* config/powerpc/ppc-sim.mt (TDEPFILES): Remove ppc-bdm.o and
> 	remote-sds.o.
> 	* config/powerpc/ppc-eabi.mt (TDEPFILES): Ditto.
> 	* config/mips/embed.mt (TDEPFILES): Remove remote-mips.o.
> 
> Andrew removes remote-mips.o from embed.mt.  This means that the boards in question,
> which talk the MIPS remote protocol, have been undebuggeable/untesteable since this
> commit, more than 9 years ago.  We currently only support, in configure.tgt:
> 
> mips*-*-elf)
>         # Target: MIPS ELF
>         gdb_target_obs="mips-tdep.o remote-mips.o"
>         gdb_sim=../sim/mips/libsim.a
>         ;;
> mips*-*-*)
>         # Target: MIPS
>         gdb_target_obs="mips-tdep.o"
>         gdb_sim=../sim/mips/libsim.a
>         ;;
> 
> 
> So I think we're pretty safe to zap any left over mips-idt bits immediately
> without going through a deprecation phase.
> 

Like so.  Tested on x86_64 Fedora 16, just in case.

gdb/doc/
2012-02-02  Pedro Alves  <palves@redhat.com>

	* gdb.texinfo (MIPS boards): Refer to mips-elf instead of
	mips-idt-ecoff.

gdb/testsuite/
2012-02-02  Pedro Alves  <palves@redhat.com>

	* config/mips-idt.exp: Delete.
	* gdb.base/a2-run.exp: Remove mips-idt xfails.
	* gdb.base/bitfields.exp: Remove mips-idt restarts.
	* gdb.base/break.exp: Remove mips-idt references.
	* gdb.base/chng-syms.exp: Ditto.
	* gdb.base/default.exp

	* gdb.base/funcargs.exp (funcargs_reload): Delete.
	(top level): Don't call it.
	* gdb.base/opaque.exp: Remove mips-idt restarts.
	* gdb.base/ptype.exp: Remove mips-idt xfails.
	* gdb.base/scope.exp: Remove mips-idt restarts.
	* gdb.base/sepdebug.exp: Remove mips-idt references.
	* gdb.base/watchpoint.exp (maybe_clean_restart)
	(maybe_reinitialize): Delete.
	(test_disabling_watchpoints, test_disabling_watchpoints)
	(test_watchpoint_triggered_in_syscall)
	(test_watchpoint_and_breakpoint, test_inaccessible_watchpoint):
	Don't call them.
---

 gdb/doc/gdb.texinfo                   |    4 ++-
 gdb/testsuite/config/mips-idt.exp     |   16 ------------
 gdb/testsuite/gdb.base/a2-run.exp     |    4 +--
 gdb/testsuite/gdb.base/bitfields.exp  |   22 -----------------
 gdb/testsuite/gdb.base/break.exp      |    3 --
 gdb/testsuite/gdb.base/chng-syms.exp  |    7 -----
 gdb/testsuite/gdb.base/default.exp    |   10 ++------
 gdb/testsuite/gdb.base/funcargs.exp   |   30 -----------------------
 gdb/testsuite/gdb.base/opaque.exp     |   10 --------
 gdb/testsuite/gdb.base/ptype.exp      |    6 ++---
 gdb/testsuite/gdb.base/scope.exp      |   28 ---------------------
 gdb/testsuite/gdb.base/sepdebug.exp   |    3 --
 gdb/testsuite/gdb.base/watchpoint.exp |   44 ---------------------------------
 13 files changed, 8 insertions(+), 179 deletions(-)
 delete mode 100644 gdb/testsuite/config/mips-idt.exp

diff --git a/gdb/doc/gdb.texinfo b/gdb/doc/gdb.texinfo
index 5738d14..083f30e 100644
--- a/gdb/doc/gdb.texinfo
+++ b/gdb/doc/gdb.texinfo
@@ -19190,7 +19190,7 @@ Show MicroBlaze-specific debugging level.
 @cindex MIPS boards
 @value{GDBN} can use the MIPS remote debugging protocol to talk to a
 MIPS board attached to a serial line.  This is available when
-you configure @value{GDBN} with @samp{--target=mips-idt-ecoff}.
+you configure @value{GDBN} with @samp{--target=mips-elf}.

 @need 1000
 Use these @value{GDBN} commands to specify the connection to your target board:
@@ -19295,7 +19295,7 @@ waiting for an acknowledgment of a packet with the @code{set
 retransmit-timeout @var{seconds}} command.  The default is 3 seconds.
 You can inspect both values with @code{show timeout} and @code{show
 retransmit-timeout}.  (These commands are @emph{only} available when
-@value{GDBN} is configured for @samp{--target=mips-idt-ecoff}.)
+@value{GDBN} is configured for @samp{--target=mips-elf}.)

 The timeout set by @code{set timeout} does not apply when @value{GDBN}
 is waiting for your program to stop.  In that case, @value{GDBN} waits
diff --git a/gdb/testsuite/config/mips-idt.exp b/gdb/testsuite/config/mips-idt.exp
deleted file mode 100644
index d3aa44e..0000000
--- a/gdb/testsuite/config/mips-idt.exp
+++ /dev/null
@@ -1,16 +0,0 @@
-#   Copyright (C) 1993, 1997, 2007-2012 Free Software Foundation, Inc.
-
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 3 of the License, or
-# (at your option) any later version.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program.  If not, see <http://www.gnu.org/licenses/>.
-
-load_lib ../config/monitor.exp
diff --git a/gdb/testsuite/gdb.base/a2-run.exp b/gdb/testsuite/gdb.base/a2-run.exp
index 4e3b54b..e2119d4 100644
--- a/gdb/testsuite/gdb.base/a2-run.exp
+++ b/gdb/testsuite/gdb.base/a2-run.exp
@@ -107,7 +107,7 @@ if [istarget "*-*-vxworks*"] then {
     verbose "Timeout is now $timeout seconds" 2
     gdb_expect -re "$gdb_prompt $" {}
 } else {
-	setup_xfail "mips-idt-*" "arm-*-coff"
+	setup_xfail "arm-*-coff"
 	gdb_run_cmd 5
 	gdb_expect {
 	    -re ".*120.*$gdb_prompt $"\
@@ -118,7 +118,6 @@ if [istarget "*-*-vxworks*"] then {
 }

 # Run again with same arguments.
-setup_xfail "mips-idt-*"
 gdb_run_cmd

 if [istarget "*-*-vxworks*"] then {
@@ -185,7 +184,6 @@ if [istarget "*-*-vxworks*"] then {
 }

 # Use "set args" command to specify an argument and run again.
-setup_xfail "mips-idt-*"
 if [istarget "*-*-vxworks*"] then {
     gdb_test_no_output "set args vxmain \"6\""
 } else {
diff --git a/gdb/testsuite/gdb.base/bitfields.exp b/gdb/testsuite/gdb.base/bitfields.exp
index 3098ffd..f5777d6 100644
--- a/gdb/testsuite/gdb.base/bitfields.exp
+++ b/gdb/testsuite/gdb.base/bitfields.exp
@@ -253,29 +253,7 @@ gdb_load ${binfile}
 gdb_test_no_output "set print sevenbit-strings"

 bitfield_uniqueness
-if [istarget "mips-idt-*"] then {
-    # Restart because IDT/SIM runs out of file descriptors.
-    gdb_exit
-    gdb_start
-    gdb_reinitialize_dir $srcdir/$subdir
-    gdb_load ${binfile}
-}
 bitfield_containment
-if [istarget "mips-idt-*"] then {
-    # Restart because IDT/SIM runs out of file descriptors.
-    gdb_exit
-    gdb_start
-    gdb_reinitialize_dir $srcdir/$subdir
-    gdb_load ${binfile}
-}
 bitfield_unsignedness
-if [istarget "mips-idt-*"] then {
-    # Restart because IDT/SIM runs out of file descriptors.
-    gdb_exit
-    gdb_start
-    gdb_reinitialize_dir $srcdir/$subdir
-    gdb_load ${binfile}
-}
 bitfield_signedness
-
 bitfield_at_offset
diff --git a/gdb/testsuite/gdb.base/break.exp b/gdb/testsuite/gdb.base/break.exp
index 9e63e2a..54cbae1 100644
--- a/gdb/testsuite/gdb.base/break.exp
+++ b/gdb/testsuite/gdb.base/break.exp
@@ -355,9 +355,6 @@ gdb_test "disable \$1foo" \
 # handle arguments.
 # Huh? There doesn't *appear* to be anything that passes arguments
 # below.
-if [istarget "mips-idt-*"] then {
-    return
-}

 #
 # run until the breakpoint at main is hit. For non-stubs-using targets.
diff --git a/gdb/testsuite/gdb.base/chng-syms.exp b/gdb/testsuite/gdb.base/chng-syms.exp
index ec5b4c8..9c20a44 100644
--- a/gdb/testsuite/gdb.base/chng-syms.exp
+++ b/gdb/testsuite/gdb.base/chng-syms.exp
@@ -18,13 +18,6 @@
 # Test that GDB cleans up properly after errors that result when a
 # breakpoint is reset.

-
-# IDT/SIM apparently doesn't have enough file descriptors to allow the
-# problem checked by this test to occur.
-if [istarget "mips-idt-*"] {
-    return 0;
-}
-
 set testfile "chng-syms"
 set srcfile ${testfile}.c
 set binfile ${objdir}/${subdir}/${testfile}
diff --git a/gdb/testsuite/gdb.base/default.exp b/gdb/testsuite/gdb.base/default.exp
index d0a8295..6a6e24e 100644
--- a/gdb/testsuite/gdb.base/default.exp
+++ b/gdb/testsuite/gdb.base/default.exp
@@ -39,7 +39,6 @@ gdb_test "append binary memory" "Missing filename\."
 gdb_test "append binary value"  "Missing filename\."

 if !$use_gdb_stub {
-    setup_xfail "mips-idt-*"
     gdb_test_multiple "attach" "attach" {
 	-re "Argument required .(process-id|program) to attach.*$gdb_prompt $"\
 	    { pass "attach" }
@@ -61,7 +60,6 @@ if !$use_gdb_stub {
     }


-    setup_xfail "mips-idt-*"
     gdb_test "backtrace" "No stack."

     # ba and bac are no longer unique command prefixes. So these tests
@@ -69,18 +67,14 @@ if !$use_gdb_stub {
     # GDB needs to be fixed to map unique alias here for ba bac.
     #
     foreach i "bt ba bac" {
-	setup_xfail "mips-idt-*"
 	gdb_test $i "No stack." "backtrace \"$i\" abbreviation"
     }
 } else {
     warning "Skipping backtrace and break tests because of GDB stub."
 }

-# This works on the MIPS IDT board, but confuses future tests.
-if ![istarget "mips-idt-*"] then {
-    gdb_test "continue" "The program is not being run." "continue"
-    gdb_test "c" "The program is not being run." "continue \"c\" abbreviation"
-}
+gdb_test "continue" "The program is not being run." "continue"
+gdb_test "c" "The program is not being run." "continue \"c\" abbreviation"

 #test call
 gdb_test "call" "The history is empty..*" "call"
diff --git a/gdb/testsuite/gdb.base/funcargs.exp b/gdb/testsuite/gdb.base/funcargs.exp
index 0b5534a..92161d7 100644
--- a/gdb/testsuite/gdb.base/funcargs.exp
+++ b/gdb/testsuite/gdb.base/funcargs.exp
@@ -965,21 +965,6 @@ proc recursive_structs_by_value {} {
     gdb_stop_suppressing_tests;
 }

-proc funcargs_reload { } {
-    global objdir
-    global subdir
-    global binfile
-    global srcdir
-
-    if [istarget "mips-idt-*"] {
-	# Restart because IDT/SIM runs out of file descriptors.
-	gdb_exit
-	gdb_start
-	gdb_reinitialize_dir $srcdir/$subdir
-	gdb_load ${binfile}
-    }
-}
-
 #
 # Test for accessing local stack variables in functions which call alloca
 #
@@ -1234,46 +1219,31 @@ gdb_test_multiple "show endian" "getting target endian" {
 gdb_test_no_output "set print frame-arguments all"

 integral_args
-funcargs_reload
 unsigned_integral_args
-funcargs_reload
 if {![target_info exists gdb,skip_float_tests]} {
   float_and_integral_args
 }

 # Test _Complex type here if supported.
 if [support_complex_tests] {
-    funcargs_reload
     complex_args

-    funcargs_reload
     complex_integral_args

     if {![target_info exists gdb,skip_float_tests]} {
-	funcargs_reload
 	complex_float_integral_args
     }
 }

-funcargs_reload
 pointer_args
-funcargs_reload
 structs_by_reference
-funcargs_reload
 structs_by_value
-funcargs_reload
 discard_and_shuffle
-funcargs_reload
 shuffle_round_robin
-funcargs_reload
 recursive_structs_by_value
-funcargs_reload
 localvars_after_alloca
-funcargs_reload
 call_after_alloca
-funcargs_reload
 localvars_in_indirect_call
-funcargs_reload
 test_stepping_over_trampolines

 set timeout $prev_timeout
diff --git a/gdb/testsuite/gdb.base/opaque.exp b/gdb/testsuite/gdb.base/opaque.exp
index b7ad265..f5fef76 100644
--- a/gdb/testsuite/gdb.base/opaque.exp
+++ b/gdb/testsuite/gdb.base/opaque.exp
@@ -134,11 +134,6 @@ gdb_test "ptype struct foo" \
 # have learned during the static tests.
 #

-if [istarget "mips-idt-*"] then {
-    # Restart because IDT/SIM runs out of file descriptors.
-    gdb_exit
-    gdb_start
-}
 gdb_reinitialize_dir $srcdir/$subdir
 gdb_load ${binfile}

@@ -189,11 +184,6 @@ gdb_test "ptype struct foo" \
 # Now reload the symbols again so we forget about anything we might
 # have learned reading the symbols during the previous tests.

-if [istarget "mips-idt-*"] then {
-    # Restart because IDT/SIM runs out of file descriptors.
-    gdb_exit
-    gdb_start
-}
 gdb_reinitialize_dir $srcdir/$subdir
 gdb_load ${binfile}

diff --git a/gdb/testsuite/gdb.base/ptype.exp b/gdb/testsuite/gdb.base/ptype.exp
index adb4cd4..51a3014 100644
--- a/gdb/testsuite/gdb.base/ptype.exp
+++ b/gdb/testsuite/gdb.base/ptype.exp
@@ -169,7 +169,7 @@ gdb_test "ptype red" "type = enum \{red, green, blue\}.*" "ptype unnamed enumera
 # acts like whatis for basic types.  If it is thought to be necessary to
 # test both whatis and ptype for all the types, the tests should be
 # merged into whatis.exp, or else maintenance will be a royal pain -kingdon
-#setup_xfail "mips-idt-*" "mips-sgi-*"
+#setup_xfail "mips-sgi-*"
 #send "ptype v_char\n"
 #gdb_expect {
 #    -re "type = char.*$gdb_prompt $"	{ pass "ptype char" }
@@ -273,7 +273,7 @@ gdb_test "ptype v_int" "type = int.*" "ptype int"
 #
 # test ptype command with arrays
 #
-#setup_xfail "mips-idt-*" "mips-sgi-*"
+#setup_xfail "mips-sgi-*"
 #send "ptype v_char_array\n"
 #gdb_expect {
 #    -re "type = char .2..*$gdb_prompt $"	{ pass "ptype char array" }
@@ -374,7 +374,7 @@ gdb_test "ptype t_char_array" "type = (|unsigned )char \\\[0?\\\]"
 ##
 ## test ptype command with pointers
 ##
-#setup_xfail "mips-idt-*" "mips-sgi-*"
+#setup_xfail "mips-sgi-*"
 #send "ptype v_char_pointer\n"
 #gdb_expect {
 #    -re "type = char \*.*$gdb_prompt $"	{ pass "ptype char pointer" }
diff --git a/gdb/testsuite/gdb.base/scope.exp b/gdb/testsuite/gdb.base/scope.exp
index a86e02d..8db7096 100644
--- a/gdb/testsuite/gdb.base/scope.exp
+++ b/gdb/testsuite/gdb.base/scope.exp
@@ -552,37 +552,9 @@ gdb_test "print 'scope0.c'::filelocal" "= 1" \
     "print 'scope0.c'::filelocal before run"

 if [runto_main] then { test_at_main }
-if [istarget "mips-idt-*"] then {
-    # Restart because IDT/SIM runs out of file descriptors.
-    gdb_exit
-    gdb_start
-    gdb_reinitialize_dir $srcdir/$subdir
-    gdb_load ${binfile}
-}
 if [runto foo] then { test_at_foo }
-if [istarget "mips-idt-*"] then {
-    # Restart because IDT/SIM runs out of file descriptors.
-    gdb_exit
-    gdb_start
-    gdb_reinitialize_dir $srcdir/$subdir
-    gdb_load ${binfile}
-}
 if [runto bar] then { test_at_bar }
-if [istarget "mips-idt-*"] then {
-    # Restart because IDT/SIM runs out of file descriptors.
-    gdb_exit
-    gdb_start
-    gdb_reinitialize_dir $srcdir/$subdir
-    gdb_load ${binfile}
-}
 if [runto localscopes] then { test_at_localscopes }
-if [istarget "mips-idt-*"] then {
-    # Restart because IDT/SIM runs out of file descriptors.
-    gdb_exit
-    gdb_start
-    gdb_reinitialize_dir $srcdir/$subdir
-    gdb_load ${binfile}
-}
 if [runto autovars] then { test_at_autovars }

 if [istarget "*-*-vxworks*"] {
diff --git a/gdb/testsuite/gdb.base/sepdebug.exp b/gdb/testsuite/gdb.base/sepdebug.exp
index ba10478..4010d33 100644
--- a/gdb/testsuite/gdb.base/sepdebug.exp
+++ b/gdb/testsuite/gdb.base/sepdebug.exp
@@ -175,9 +175,6 @@ gdb_test "info break" \
 # handle arguments.
 # Huh? There doesn't *appear* to be anything that passes arguments
 # below.
-if [istarget "mips-idt-*"] then {
-    return
-}

 #
 # run until the breakpoint at main is hit. For non-stubs-using targets.
diff --git a/gdb/testsuite/gdb.base/watchpoint.exp b/gdb/testsuite/gdb.base/watchpoint.exp
index 5070914..381c26e 100644
--- a/gdb/testsuite/gdb.base/watchpoint.exp
+++ b/gdb/testsuite/gdb.base/watchpoint.exp
@@ -92,40 +92,6 @@ proc initialize {} {
     return 1
 }

-proc maybe_clean_restart { } {
-    # The IDT/sim monitor only has 8 (!) open files, of which it uses
-    # 4 (!).  So we have to make sure one program exits before
-    # starting another one.
-    if [istarget "mips-idt-*"] then {
-	global testfile
-	global no_hw
-
-	clean_restart $testfile
-
-	if {$no_hw} {
-	    gdb_test_no_output "set can-use-hw-watchpoints 0" ""
-	}
-    }
-}
-
-proc maybe_reinitialize { } {
-    # The IDT/sim monitor only has 8 (!) open files, of which it uses
-    # 4 (!).  So we have to make sure one program exits before
-    # starting another one.
-    if [istarget "mips-idt-*"] then {
-	global testfile
-	global no_hw
-
-	clean_restart $testfile
-
-	if {$no_hw} {
-	    gdb_test_no_output "set can-use-hw-watchpoints 0" ""
-	}
-
-	initialize
-    }
-}
-
 #
 # Test simple watchpoint.
 #
@@ -246,8 +212,6 @@ proc test_disabling_watchpoints {} {
     global decimal
     global hex

-    maybe_reinitialize
-
     gdb_test "info watch" "\[0-9]+\[ \]*.*watchpoint.*ival3.*" "watchpoints found in watchpoint/breakpoint table"

     # Ensure that the watchpoint is disabled when we startup.
@@ -312,8 +276,6 @@ proc test_disabling_watchpoints {} {
 proc test_stepping {} {
     global gdb_prompt

-    maybe_clean_restart
-
     if [runto marker1] then {
 	gdb_test "watch ival2" ".*\[Ww\]atchpoint \[0-9\]*: ival2"

@@ -473,8 +435,6 @@ proc test_watchpoint_triggered_in_syscall {} {
 proc test_complex_watchpoint {} {
     global gdb_prompt

-    maybe_clean_restart
-
     if [runto marker4] then {
 	gdb_test "watch ptr1->val" ".*\[Ww\]atchpoint \[0-9\]*: ptr1->val"
 	gdb_test "break marker5" ".*Breakpoint.*"
@@ -577,8 +537,6 @@ proc test_complex_watchpoint {} {
 proc test_watchpoint_and_breakpoint {} {
     global gdb_prompt

-    maybe_clean_restart
-
     # This is a test for PR gdb/38, which involves setting a
     # watchpoint right after you've reached a breakpoint.

@@ -708,8 +666,6 @@ proc test_wide_location_2 {} {
 proc test_inaccessible_watchpoint {} {
     global gdb_prompt

-    maybe_clean_restart
-
     # This is a test for watchpoints on currently inaccessible (but later
     # valid) memory.


-- 
Pedro Alves



More information about the Gdb-patches mailing list