From: Tom de Vries Date: Wed, 3 Sep 2025 14:05:07 +0000 (+0200) Subject: [gdb/testsuite] Fix mi_clean_restart in gdb.mi X-Git-Tag: gdb-17-branchpoint~60 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=e9aaad19842821b4cd6785bf0aa7c46df6186230;p=thirdparty%2Fbinutils-gdb.git [gdb/testsuite] Fix mi_clean_restart in gdb.mi Fix mi_clean_restart in the test-cases in gdb.mi. Tested on x86_64-linux. Also tested test-case gdb.mi/mi-dprintf.exp with target boards native-gdbserver and native-extended-gdbserver. Since test-case gdb.mi/mi-regs.exp requires istarget "sparc-*-*", I didn't test the trivial change in that test-case. --- diff --git a/gdb/testsuite/gdb.mi/dw2-ref-missing-frame.exp b/gdb/testsuite/gdb.mi/dw2-ref-missing-frame.exp index 3fd9b81460f..05656817b99 100644 --- a/gdb/testsuite/gdb.mi/dw2-ref-missing-frame.exp +++ b/gdb/testsuite/gdb.mi/dw2-ref-missing-frame.exp @@ -42,7 +42,7 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" $objsfile object {}] != "" return -1 } -if {[mi_clean_restart $binfile]} { +if {[mi_clean_restart $::testfile]} { return } @@ -54,7 +54,7 @@ if [mi_runto func_nofb_marker] { } # GDB could have crashed. -if {[mi_clean_restart $binfile]} { +if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/gdb2549.exp b/gdb/testsuite/gdb.mi/gdb2549.exp index 796c1faafb9..5aabc3b1f69 100644 --- a/gdb/testsuite/gdb.mi/gdb2549.exp +++ b/gdb/testsuite/gdb.mi/gdb2549.exp @@ -94,7 +94,7 @@ proc register_tests { } { register_test 666 t $binary } -mi_clean_restart $binfile +mi_clean_restart $::testfile register_tests_no_exec diff --git a/gdb/testsuite/gdb.mi/gdb669.exp b/gdb/testsuite/gdb.mi/gdb669.exp index 086d3c1a344..da1db640346 100644 --- a/gdb/testsuite/gdb.mi/gdb669.exp +++ b/gdb/testsuite/gdb.mi/gdb669.exp @@ -30,7 +30,7 @@ if {[gdb_compile_pthreads "$srcdir/$subdir/$srcfile" $binfile executable $option return -1 } -mi_clean_restart $binfile +mi_clean_restart $::testfile mi_runto_main check_mi_and_console_threads "at main" diff --git a/gdb/testsuite/gdb.mi/gdb701.exp b/gdb/testsuite/gdb.mi/gdb701.exp index 587481c414a..9ef6fb7a6c3 100644 --- a/gdb/testsuite/gdb.mi/gdb701.exp +++ b/gdb/testsuite/gdb.mi/gdb701.exp @@ -35,7 +35,7 @@ if {[gdb_compile $srcdir/$subdir/$srcfile $binfile executable debug] != ""} { # If it doesn't, Bad Things Happen(TM). # Run to main -mi_clean_restart $binfile +mi_clean_restart $::testfile mi_runto_main # Step over "foo = 0" diff --git a/gdb/testsuite/gdb.mi/gdb792.exp b/gdb/testsuite/gdb.mi/gdb792.exp index f894eea7d9a..64f218a2feb 100644 --- a/gdb/testsuite/gdb.mi/gdb792.exp +++ b/gdb/testsuite/gdb.mi/gdb792.exp @@ -28,7 +28,7 @@ if {[gdb_compile $srcdir/$subdir/$srcfile $binfile executable {debug c++}] != "" return -1 } -mi_clean_restart $binfile +mi_clean_restart $::testfile mi_runto_main diff --git a/gdb/testsuite/gdb.mi/interrupt-thread-group.exp b/gdb/testsuite/gdb.mi/interrupt-thread-group.exp index 869fb1cb287..5f9e49eceda 100644 --- a/gdb/testsuite/gdb.mi/interrupt-thread-group.exp +++ b/gdb/testsuite/gdb.mi/interrupt-thread-group.exp @@ -30,7 +30,7 @@ if {[gdb_compile_pthreads "$srcdir/$subdir/$srcfile" $binfile \ save_vars { GDBFLAGS } { append GDBFLAGS " -ex \"set non-stop on\" -ex \"set mi-async\"" - mi_clean_restart $binfile + mi_clean_restart $::testfile } mi_detect_async diff --git a/gdb/testsuite/gdb.mi/mi-add-inferior.exp b/gdb/testsuite/gdb.mi/mi-add-inferior.exp index d110e6840e1..8c4926fcf15 100644 --- a/gdb/testsuite/gdb.mi/mi-add-inferior.exp +++ b/gdb/testsuite/gdb.mi/mi-add-inferior.exp @@ -26,7 +26,7 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" \ return -1 } -mi_clean_restart ${binfile} +mi_clean_restart ${::testfile} # Start execution to establish a connection. mi_runto_main diff --git a/gdb/testsuite/gdb.mi/mi-async-run.exp b/gdb/testsuite/gdb.mi/mi-async-run.exp index 83528037336..3df8769dfa0 100644 --- a/gdb/testsuite/gdb.mi/mi-async-run.exp +++ b/gdb/testsuite/gdb.mi/mi-async-run.exp @@ -35,7 +35,7 @@ proc test_async_run {} { set GDBFLAGS [concat $GDBFLAGS " -ex \"set mi-async on\""] - if {[mi_clean_restart $binfile]} { + if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-async.exp b/gdb/testsuite/gdb.mi/mi-async.exp index 09db7f91050..1c4e06cd3a4 100644 --- a/gdb/testsuite/gdb.mi/mi-async.exp +++ b/gdb/testsuite/gdb.mi/mi-async.exp @@ -42,7 +42,7 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {deb save_vars { GDBFLAGS } { set GDBFLAGS [concat $GDBFLAGS " -ex \"set mi-async on\""] - if {[mi_clean_restart $binfile]} { + if {[mi_clean_restart $::testfile]} { return } } diff --git a/gdb/testsuite/gdb.mi/mi-break-qualified.exp b/gdb/testsuite/gdb.mi/mi-break-qualified.exp index b5e5e78aa15..9adc2d90460 100644 --- a/gdb/testsuite/gdb.mi/mi-break-qualified.exp +++ b/gdb/testsuite/gdb.mi/mi-break-qualified.exp @@ -93,7 +93,7 @@ proc test_break_qualified {} { "delete temp breakpoints" } -if {[mi_clean_restart $binfile]} { +if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-break.exp b/gdb/testsuite/gdb.mi/mi-break.exp index bb982c377fc..2a212c37496 100644 --- a/gdb/testsuite/gdb.mi/mi-break.exp +++ b/gdb/testsuite/gdb.mi/mi-break.exp @@ -398,7 +398,7 @@ proc test_break {mi_mode} { } else { set start_ops "" } - if [mi_clean_restart $binfile $start_ops ] { + if [mi_clean_restart $::testfile $start_ops ] { return } diff --git a/gdb/testsuite/gdb.mi/mi-breakpoint-changed.exp b/gdb/testsuite/gdb.mi/mi-breakpoint-changed.exp index 9cb91de7c7f..46561e48b79 100644 --- a/gdb/testsuite/gdb.mi/mi-breakpoint-changed.exp +++ b/gdb/testsuite/gdb.mi/mi-breakpoint-changed.exp @@ -48,7 +48,7 @@ proc test_insert_delete_modify { } { global lib_sl1 lib_sl2 global binfile - mi_clean_restart $binfile + mi_clean_restart $::testfile mi_load_shlibs $lib_sl1 $lib_sl2 @@ -184,7 +184,7 @@ proc test_pending_resolved { } { global lib_sl1 lib_sl2 global mi_gdb_prompt - if {[mi_clean_restart $binfile]} { + if {[mi_clean_restart $::testfile]} { return } mi_load_shlibs $lib_sl1 $lib_sl2 @@ -279,7 +279,7 @@ proc test_auto_disable { } { global lib_sl1 lib_sl2 global binfile - mi_clean_restart $binfile + mi_clean_restart $::testfile mi_load_shlibs $lib_sl1 $lib_sl2 diff --git a/gdb/testsuite/gdb.mi/mi-breakpoint-multiple-locations.exp b/gdb/testsuite/gdb.mi/mi-breakpoint-multiple-locations.exp index cbf9f57c79a..79958467718 100644 --- a/gdb/testsuite/gdb.mi/mi-breakpoint-multiple-locations.exp +++ b/gdb/testsuite/gdb.mi/mi-breakpoint-multiple-locations.exp @@ -56,7 +56,7 @@ proc do_test { mi_version use_fix_flag expect_fixed_output } { global MIFLAGS decimal binfile set MIFLAGS "-i=mi${mi_version}" - mi_clean_restart $binfile + mi_clean_restart $::testfile mi_runto_main diff --git a/gdb/testsuite/gdb.mi/mi-breakpoint-script.exp b/gdb/testsuite/gdb.mi/mi-breakpoint-script.exp index af514e8aa39..ce30d4404b6 100644 --- a/gdb/testsuite/gdb.mi/mi-breakpoint-script.exp +++ b/gdb/testsuite/gdb.mi/mi-breakpoint-script.exp @@ -51,7 +51,7 @@ proc do_test { mi_version use_fix_flag expect_fixed_output } { save_vars { ::MIFLAGS } { set ::MIFLAGS "-i=mi${mi_version}" - mi_clean_restart $::binfile + mi_clean_restart $::testfile } if $use_fix_flag { diff --git a/gdb/testsuite/gdb.mi/mi-catch-cpp-exceptions.exp b/gdb/testsuite/gdb.mi/mi-catch-cpp-exceptions.exp index 9053b181516..ec023e666aa 100644 --- a/gdb/testsuite/gdb.mi/mi-catch-cpp-exceptions.exp +++ b/gdb/testsuite/gdb.mi/mi-catch-cpp-exceptions.exp @@ -27,7 +27,7 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {deb return -1 } -mi_clean_restart $binfile +mi_clean_restart $::testfile if {[mi_runto_main] < 0} { return -1 } @@ -46,7 +46,7 @@ proc restart_for_test {} { global srcdir subdir binfile srcfile global main_lineno - if {[mi_clean_restart $binfile]} { + if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-catch-load.exp b/gdb/testsuite/gdb.mi/mi-catch-load.exp index a9a5fdcda68..3c36cc908c7 100644 --- a/gdb/testsuite/gdb.mi/mi-catch-load.exp +++ b/gdb/testsuite/gdb.mi/mi-catch-load.exp @@ -36,7 +36,7 @@ gdb_download_shlib $binfile2 # test -catch-load with_test_prefix "catch-load" { - mi_clean_restart $binfile + mi_clean_restart $::testfile mi_locate_shlib $binfile2 mi_runto_main @@ -63,7 +63,7 @@ with_test_prefix "catch-load" { # test -catch-unload with_test_prefix "catch-unload" { - mi_clean_restart $binfile + mi_clean_restart $::testfile mi_locate_shlib $binfile2 mi_runto_main diff --git a/gdb/testsuite/gdb.mi/mi-cli.exp b/gdb/testsuite/gdb.mi/mi-cli.exp index a3ff7ebe9c6..b59a5ed3f98 100644 --- a/gdb/testsuite/gdb.mi/mi-cli.exp +++ b/gdb/testsuite/gdb.mi/mi-cli.exp @@ -29,7 +29,7 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {deb return -1 } -mi_clean_restart $binfile +mi_clean_restart $::testfile mi_gdb_test "-interpreter-exec" \ {\^error,msg="-interpreter-exec: Usage: -interpreter-exec interp command"} \ diff --git a/gdb/testsuite/gdb.mi/mi-cmd-param-changed.exp b/gdb/testsuite/gdb.mi/mi-cmd-param-changed.exp index 5587b762751..24d12c1192b 100644 --- a/gdb/testsuite/gdb.mi/mi-cmd-param-changed.exp +++ b/gdb/testsuite/gdb.mi/mi-cmd-param-changed.exp @@ -31,7 +31,7 @@ proc test_command_param_changed { } { global binfile with_test_prefix "cmd param" { - mi_clean_restart $binfile + mi_clean_restart $::testfile mi_runto_main if { $scheduler_locking_supported } { diff --git a/gdb/testsuite/gdb.mi/mi-cmd-user-context.exp b/gdb/testsuite/gdb.mi/mi-cmd-user-context.exp index 806ed4c8e48..324de5ab5e8 100644 --- a/gdb/testsuite/gdb.mi/mi-cmd-user-context.exp +++ b/gdb/testsuite/gdb.mi/mi-cmd-user-context.exp @@ -29,7 +29,7 @@ set main_break_line [gdb_get_line_number "main break line"] set any "\[^\r\n\]*" -mi_clean_restart $binfile +mi_clean_restart $::testfile mi_create_breakpoint "$srcfile:$main_break_line" "set breakpoint in main" mi_run_cmd mi_expect_stop "breakpoint-hit" "main" "" $srcfile $main_break_line \ diff --git a/gdb/testsuite/gdb.mi/mi-complete.exp b/gdb/testsuite/gdb.mi/mi-complete.exp index 22acda3d373..ad29b3f80b2 100644 --- a/gdb/testsuite/gdb.mi/mi-complete.exp +++ b/gdb/testsuite/gdb.mi/mi-complete.exp @@ -26,7 +26,7 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debu return -1 } -mi_clean_restart $binfile +mi_clean_restart $::testfile # Don't run to main to avoid increasing the search scope to include # debug info of shared libraries like glibc, libgcc, etc. diff --git a/gdb/testsuite/gdb.mi/mi-condbreak-call-thr-state.exp b/gdb/testsuite/gdb.mi/mi-condbreak-call-thr-state.exp index 02d02b2ab17..7708a6d15ab 100644 --- a/gdb/testsuite/gdb.mi/mi-condbreak-call-thr-state.exp +++ b/gdb/testsuite/gdb.mi/mi-condbreak-call-thr-state.exp @@ -59,7 +59,7 @@ proc test { variant } { return -1 } - if {[mi_clean_restart $binfile]} { + if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-condbreak-fail.exp b/gdb/testsuite/gdb.mi/mi-condbreak-fail.exp index 43b1e2f44f2..5bd89932540 100644 --- a/gdb/testsuite/gdb.mi/mi-condbreak-fail.exp +++ b/gdb/testsuite/gdb.mi/mi-condbreak-fail.exp @@ -35,7 +35,7 @@ if [build_executable ${testfile}.exp ${binfile} ${srcfile}] { proc run_test { unwind_on_signal } { - if {[mi_clean_restart $::binfile]} { + if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-condbreak-throw.exp b/gdb/testsuite/gdb.mi/mi-condbreak-throw.exp index 0a89a8a99bc..b4960a858da 100644 --- a/gdb/testsuite/gdb.mi/mi-condbreak-throw.exp +++ b/gdb/testsuite/gdb.mi/mi-condbreak-throw.exp @@ -38,7 +38,7 @@ if [build_executable ${testfile}.exp ${binfile} ${srcfile} {debug c++}] { proc run_test { unwind_on_exception } { - if {[mi_clean_restart $::binfile]} { + if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-console.exp b/gdb/testsuite/gdb.mi/mi-console.exp index efb1ea97197..861ef426597 100644 --- a/gdb/testsuite/gdb.mi/mi-console.exp +++ b/gdb/testsuite/gdb.mi/mi-console.exp @@ -53,7 +53,7 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {deb return -1 } -if {[mi_clean_restart $binfile]} { +if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-detach.exp b/gdb/testsuite/gdb.mi/mi-detach.exp index ff983c1252b..b485a9bc535 100644 --- a/gdb/testsuite/gdb.mi/mi-detach.exp +++ b/gdb/testsuite/gdb.mi/mi-detach.exp @@ -25,7 +25,7 @@ if {[build_executable $testfile.exp $testfile $srcfile {debug}] == -1} { return -1 } -mi_clean_restart $binfile +mi_clean_restart $::testfile mi_runto_main mi_gdb_test "-target-detach" "=thread-exited,id=\"1\".*=thread-group-exited,id=\"i1\".*" "detach" diff --git a/gdb/testsuite/gdb.mi/mi-disassemble.exp b/gdb/testsuite/gdb.mi/mi-disassemble.exp index 15ead332670..90f79e384de 100644 --- a/gdb/testsuite/gdb.mi/mi-disassemble.exp +++ b/gdb/testsuite/gdb.mi/mi-disassemble.exp @@ -345,7 +345,7 @@ proc test_disassembly_opcode_format {} { "data-disassemble checking the opcodes bytes format" } -mi_clean_restart $binfile +mi_clean_restart $::testfile mi_runto_main test_disassembly_only test_disassembly_with_opcodes diff --git a/gdb/testsuite/gdb.mi/mi-dlmopen.exp b/gdb/testsuite/gdb.mi/mi-dlmopen.exp index 936027fba47..0e1d0bcd618 100644 --- a/gdb/testsuite/gdb.mi/mi-dlmopen.exp +++ b/gdb/testsuite/gdb.mi/mi-dlmopen.exp @@ -132,7 +132,7 @@ proc get_dyld_info {} { # number of unload events for the libraries created for this test, and # additionally, check for dynamic linker unload events. proc check_solib_unload_events {} { - mi_clean_restart $::binfile + mi_clean_restart $::testfile if {[mi_runto_main] == -1} { return diff --git a/gdb/testsuite/gdb.mi/mi-dprintf-modified.exp b/gdb/testsuite/gdb.mi/mi-dprintf-modified.exp index c3e1bdf9180..0584a860bf8 100644 --- a/gdb/testsuite/gdb.mi/mi-dprintf-modified.exp +++ b/gdb/testsuite/gdb.mi/mi-dprintf-modified.exp @@ -52,7 +52,7 @@ if { [build_executable "build exec" $binfile $srcfile $opts] == -1} { set bp_line [gdb_get_line_number "Break here" $srcfile] # Start the inferior. -mi_clean_restart $binfile +mi_clean_restart $::testfile mi_runto_main # Place a breakpoint at the dlopen() line. diff --git a/gdb/testsuite/gdb.mi/mi-dprintf-pending.exp b/gdb/testsuite/gdb.mi/mi-dprintf-pending.exp index 2df9ad46996..3685e420a18 100644 --- a/gdb/testsuite/gdb.mi/mi-dprintf-pending.exp +++ b/gdb/testsuite/gdb.mi/mi-dprintf-pending.exp @@ -39,7 +39,7 @@ if {[gdb_compile $srcdir/$subdir/$srcfile $binfile executable $exec_opts] != ""} return -1 } -if {[mi_clean_restart $binfile]} { +if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-dprintf.exp b/gdb/testsuite/gdb.mi/mi-dprintf.exp index 5d448e42b97..9d0b95a24cf 100644 --- a/gdb/testsuite/gdb.mi/mi-dprintf.exp +++ b/gdb/testsuite/gdb.mi/mi-dprintf.exp @@ -31,7 +31,7 @@ if {[build_executable $testfile.exp $testfile $srcfile $flags] == -1} { set bp_location1 [gdb_get_line_number "set breakpoint 1 here"] set dp_location1 [gdb_get_line_number "set dprintf 1 here"] -mi_clean_restart $binfile +mi_clean_restart $::testfile mi_runto_main set i 0 diff --git a/gdb/testsuite/gdb.mi/mi-eval.exp b/gdb/testsuite/gdb.mi/mi-eval.exp index 27c27f59fd3..2b2189582df 100644 --- a/gdb/testsuite/gdb.mi/mi-eval.exp +++ b/gdb/testsuite/gdb.mi/mi-eval.exp @@ -32,7 +32,7 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {deb return -1 } -if {[mi_clean_restart $binfile]} { +if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-exit-code.exp b/gdb/testsuite/gdb.mi/mi-exit-code.exp index 344d5656e15..af2c6bd92c8 100644 --- a/gdb/testsuite/gdb.mi/mi-exit-code.exp +++ b/gdb/testsuite/gdb.mi/mi-exit-code.exp @@ -36,7 +36,7 @@ proc test_list_thread_groups { } { "122\\^done,groups=\\\[\{id=\"i1\",type=\"process\"\}\]" \ "-list-thread-groups before run shows no exit-code" - mi_clean_restart $binfile + mi_clean_restart $::testfile with_test_prefix "first run" { mi_runto_main diff --git a/gdb/testsuite/gdb.mi/mi-fill-memory.exp b/gdb/testsuite/gdb.mi/mi-fill-memory.exp index 0afc258dccd..ab7e03a87b0 100644 --- a/gdb/testsuite/gdb.mi/mi-fill-memory.exp +++ b/gdb/testsuite/gdb.mi/mi-fill-memory.exp @@ -27,7 +27,7 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile}.c" "${binfile}" executable {d return -1 } -mi_clean_restart $binfile +mi_clean_restart $::testfile mi_runto_main mi_next_to "main" "" "mi-read-memory.c" "20" "next at main" diff --git a/gdb/testsuite/gdb.mi/mi-fortran-modules.exp b/gdb/testsuite/gdb.mi/mi-fortran-modules.exp index 88867023496..48391bc18c1 100644 --- a/gdb/testsuite/gdb.mi/mi-fortran-modules.exp +++ b/gdb/testsuite/gdb.mi/mi-fortran-modules.exp @@ -28,7 +28,7 @@ if {[build_executable "failed to prepare" ${testfile} \ return -1 } -mi_clean_restart $binfile +mi_clean_restart $::testfile mi_runto_main diff --git a/gdb/testsuite/gdb.mi/mi-frame-regs.exp b/gdb/testsuite/gdb.mi/mi-frame-regs.exp index f31e4a18620..990abd5bd60 100644 --- a/gdb/testsuite/gdb.mi/mi-frame-regs.exp +++ b/gdb/testsuite/gdb.mi/mi-frame-regs.exp @@ -62,7 +62,7 @@ proc_with_prefix do_floating_varobj_test {} { global hex global expect_out - if {[mi_clean_restart $binfile]} { + if {[mi_clean_restart $::testfile]} { fail "couldn't start gdb" return } @@ -113,7 +113,7 @@ proc_with_prefix do_fixed_varobj_test {} { global srcfile binfile global hex - if {[mi_clean_restart $binfile] != 0} { + if {[mi_clean_restart $::testfile] != 0} { fail "couldn't start gdb" return } diff --git a/gdb/testsuite/gdb.mi/mi-fullname-deleted.exp b/gdb/testsuite/gdb.mi/mi-fullname-deleted.exp index 130b5bff264..6c1dbec15fe 100644 --- a/gdb/testsuite/gdb.mi/mi-fullname-deleted.exp +++ b/gdb/testsuite/gdb.mi/mi-fullname-deleted.exp @@ -58,7 +58,7 @@ if { [gdb_compile "$srcfileabs" "${binfile}" executable {debug}] != "" } { file delete -- $srcfileabs -if {[mi_clean_restart $binfile]} { +if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-info-os.exp b/gdb/testsuite/gdb.mi/mi-info-os.exp index 5d8d3ffa465..c70dac6c6d6 100644 --- a/gdb/testsuite/gdb.mi/mi-info-os.exp +++ b/gdb/testsuite/gdb.mi/mi-info-os.exp @@ -32,7 +32,7 @@ if [build_executable "Failed to build $testfile" $testfile $srcfile \ return -1; } -if {[mi_clean_restart $binfile]} { +if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-info-sources.exp b/gdb/testsuite/gdb.mi/mi-info-sources.exp index f44fc29e86e..80ca5967fe1 100644 --- a/gdb/testsuite/gdb.mi/mi-info-sources.exp +++ b/gdb/testsuite/gdb.mi/mi-info-sources.exp @@ -26,7 +26,7 @@ if {[build_executable $testfile.exp $testfile \ return -1 } -mi_clean_restart $binfile +mi_clean_restart $::testfile set readnow_p [mi_readnow] diff --git a/gdb/testsuite/gdb.mi/mi-inheritance-syntax-error.exp b/gdb/testsuite/gdb.mi/mi-inheritance-syntax-error.exp index 0ab2de27267..3092b6922de 100644 --- a/gdb/testsuite/gdb.mi/mi-inheritance-syntax-error.exp +++ b/gdb/testsuite/gdb.mi/mi-inheritance-syntax-error.exp @@ -25,7 +25,7 @@ if {[gdb_compile $srcdir/$subdir/$srcfile $binfile executable {debug c++}] != "" return -1 } -if {[mi_clean_restart $binfile]} { +if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-linespec-err-cp.exp b/gdb/testsuite/gdb.mi/mi-linespec-err-cp.exp index 3314d5f45dd..7eeb25909f0 100644 --- a/gdb/testsuite/gdb.mi/mi-linespec-err-cp.exp +++ b/gdb/testsuite/gdb.mi/mi-linespec-err-cp.exp @@ -29,7 +29,7 @@ if {[build_executable "failed to prepare" $exefile $srcfile {debug c++}]} { return -1 } -mi_clean_restart $binfile +mi_clean_restart $::testfile # Turn off the pending breakpoint queries. mi_gdb_test "-interpreter-exec console \"set breakpoint pending off\"" \ diff --git a/gdb/testsuite/gdb.mi/mi-logging.exp b/gdb/testsuite/gdb.mi/mi-logging.exp index de76e02fd35..82355913faf 100644 --- a/gdb/testsuite/gdb.mi/mi-logging.exp +++ b/gdb/testsuite/gdb.mi/mi-logging.exp @@ -24,7 +24,7 @@ if [build_executable $testfile.exp $testfile $srcfile $opts] { return -1 } -mi_clean_restart $binfile +mi_clean_restart $::testfile if {[mi_runto_main] < 0} { return -1 diff --git a/gdb/testsuite/gdb.mi/mi-memory-changed.exp b/gdb/testsuite/gdb.mi/mi-memory-changed.exp index bc2b6c38085..6d02c334944 100644 --- a/gdb/testsuite/gdb.mi/mi-memory-changed.exp +++ b/gdb/testsuite/gdb.mi/mi-memory-changed.exp @@ -22,7 +22,7 @@ if { [gdb_compile "$srcdir/$subdir/$srcfile" $binfile \ load_lib mi-support.exp -if {[mi_clean_restart $binfile]} { +if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-nonstop-exit.exp b/gdb/testsuite/gdb.mi/mi-nonstop-exit.exp index 599e460f79c..4729033347a 100644 --- a/gdb/testsuite/gdb.mi/mi-nonstop-exit.exp +++ b/gdb/testsuite/gdb.mi/mi-nonstop-exit.exp @@ -30,7 +30,7 @@ if {[gdb_compile_pthreads "$srcdir/$subdir/$srcfile" $binfile executable $option save_vars { GDBFLAGS } { append GDBFLAGS " -ex \"set non-stop on\"" - mi_clean_restart $binfile + mi_clean_restart $::testfile } mi_gdb_test "-gdb-set mi-async 1" ".*" diff --git a/gdb/testsuite/gdb.mi/mi-nonstop.exp b/gdb/testsuite/gdb.mi/mi-nonstop.exp index b8efef7c261..1ba37a33331 100644 --- a/gdb/testsuite/gdb.mi/mi-nonstop.exp +++ b/gdb/testsuite/gdb.mi/mi-nonstop.exp @@ -41,7 +41,7 @@ if {[gdb_compile_pthreads "$srcdir/$subdir/$srcfile" $binfile executable $option save_vars { GDBFLAGS } { append GDBFLAGS " -ex \"set non-stop on\"" - mi_clean_restart $binfile + mi_clean_restart $::testfile } mi_gdb_test "-gdb-set mi-async 1" ".*" diff --git a/gdb/testsuite/gdb.mi/mi-ns-stale-regcache.exp b/gdb/testsuite/gdb.mi/mi-ns-stale-regcache.exp index 20d9e45bc72..20936f18709 100644 --- a/gdb/testsuite/gdb.mi/mi-ns-stale-regcache.exp +++ b/gdb/testsuite/gdb.mi/mi-ns-stale-regcache.exp @@ -43,7 +43,7 @@ if {[gdb_compile "$srcdir/$subdir/$srcfile" \ save_vars { GDBFLAGS } { append GDBFLAGS " -ex \"set non-stop on\"" - mi_clean_restart $binfile + mi_clean_restart $::testfile } mi_gdb_test "-gdb-set mi-async 1" ".*" diff --git a/gdb/testsuite/gdb.mi/mi-nsintrall.exp b/gdb/testsuite/gdb.mi/mi-nsintrall.exp index 983c0fea03c..8c8aef8cd5a 100644 --- a/gdb/testsuite/gdb.mi/mi-nsintrall.exp +++ b/gdb/testsuite/gdb.mi/mi-nsintrall.exp @@ -30,7 +30,7 @@ if {[gdb_compile_pthreads "$srcdir/$subdir/$srcfile" $binfile executable $option save_vars { GDBFLAGS } { append GDBFLAGS " -ex \"set non-stop on\"" - mi_clean_restart $binfile + mi_clean_restart $::testfile } mi_gdb_test "-gdb-set mi-async 1" ".*" diff --git a/gdb/testsuite/gdb.mi/mi-nsmoribund.exp b/gdb/testsuite/gdb.mi/mi-nsmoribund.exp index da43a9327a1..2307c2e34b9 100644 --- a/gdb/testsuite/gdb.mi/mi-nsmoribund.exp +++ b/gdb/testsuite/gdb.mi/mi-nsmoribund.exp @@ -30,7 +30,7 @@ if {[gdb_compile_pthreads "$srcdir/$subdir/$srcfile" $binfile executable $option save_vars { GDBFLAGS } { append GDBFLAGS " -ex \"set non-stop on\"" - mi_clean_restart $binfile + mi_clean_restart $::testfile } mi_gdb_test "-gdb-set mi-async 1" ".*" diff --git a/gdb/testsuite/gdb.mi/mi-nsthrexec.exp b/gdb/testsuite/gdb.mi/mi-nsthrexec.exp index fd8aa54a72f..1f9d1ae2a06 100644 --- a/gdb/testsuite/gdb.mi/mi-nsthrexec.exp +++ b/gdb/testsuite/gdb.mi/mi-nsthrexec.exp @@ -35,7 +35,7 @@ if {[gdb_compile_pthreads "$srcdir/$subdir/$srcfile" $binfile executable $option save_vars { GDBFLAGS } { append GDBFLAGS " -ex \"set non-stop on\"" - mi_clean_restart $binfile + mi_clean_restart $::testfile } mi_gdb_test "-gdb-set mi-async 1" ".*" diff --git a/gdb/testsuite/gdb.mi/mi-pending.exp b/gdb/testsuite/gdb.mi/mi-pending.exp index 49839cb0282..eb0719cb07e 100644 --- a/gdb/testsuite/gdb.mi/mi-pending.exp +++ b/gdb/testsuite/gdb.mi/mi-pending.exp @@ -45,7 +45,7 @@ if { [gdb_compile_pthreads $srcdir/$subdir/$srcfile $binfile executable $exec_op } # Start with a fresh gdb. -if {[mi_clean_restart $binfile]} { +if {[mi_clean_restart $::testfile]} { return } mi_load_shlibs $lib_sl1 diff --git a/gdb/testsuite/gdb.mi/mi-pthreads.exp b/gdb/testsuite/gdb.mi/mi-pthreads.exp index 93f03446375..117b2de69f3 100644 --- a/gdb/testsuite/gdb.mi/mi-pthreads.exp +++ b/gdb/testsuite/gdb.mi/mi-pthreads.exp @@ -63,7 +63,7 @@ if {[gdb_compile_pthreads "$srcdir/$subdir/$srcfile" $binfile executable $option return -1 } -if {[mi_clean_restart $binfile]} { +if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-py-modify-bp.exp b/gdb/testsuite/gdb.mi/mi-py-modify-bp.exp index 419375775b0..5175899203d 100644 --- a/gdb/testsuite/gdb.mi/mi-py-modify-bp.exp +++ b/gdb/testsuite/gdb.mi/mi-py-modify-bp.exp @@ -31,7 +31,7 @@ if {[build_executable $testfile.exp $testfile $srcfile] == -1} { set remote_python_file [gdb_remote_download host \ ${srcdir}/${subdir}/${testfile}.py] -mi_clean_restart $binfile +mi_clean_restart $::testfile mi_runto_main # Delete all breakpoints, watchpoints, tracepoints, and catchpoints. diff --git a/gdb/testsuite/gdb.mi/mi-read-memory.exp b/gdb/testsuite/gdb.mi/mi-read-memory.exp index 8de8728e9c9..4469123b275 100644 --- a/gdb/testsuite/gdb.mi/mi-read-memory.exp +++ b/gdb/testsuite/gdb.mi/mi-read-memory.exp @@ -25,7 +25,7 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {deb return -1 } -mi_clean_restart $binfile +mi_clean_restart $::testfile mi_runto_main mi_next_to "main" "" "mi-read-memory.c" "20" "next at main" diff --git a/gdb/testsuite/gdb.mi/mi-record-changed.exp b/gdb/testsuite/gdb.mi/mi-record-changed.exp index e37540b38e3..986efd921c1 100644 --- a/gdb/testsuite/gdb.mi/mi-record-changed.exp +++ b/gdb/testsuite/gdb.mi/mi-record-changed.exp @@ -24,7 +24,7 @@ if { [gdb_compile "$srcdir/$subdir/$srcfile" $binfile \ load_lib mi-support.exp -mi_clean_restart $binfile +mi_clean_restart $::testfile mi_runto_main diff --git a/gdb/testsuite/gdb.mi/mi-reg-undefined.exp b/gdb/testsuite/gdb.mi/mi-reg-undefined.exp index c7e0564cc7c..ef102ceee03 100644 --- a/gdb/testsuite/gdb.mi/mi-reg-undefined.exp +++ b/gdb/testsuite/gdb.mi/mi-reg-undefined.exp @@ -29,7 +29,7 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {deb return -1 } -if {[mi_clean_restart $binfile]} { +if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-regs.exp b/gdb/testsuite/gdb.mi/mi-regs.exp index 0bb305b1baa..aae00a62047 100644 --- a/gdb/testsuite/gdb.mi/mi-regs.exp +++ b/gdb/testsuite/gdb.mi/mi-regs.exp @@ -108,7 +108,7 @@ require {istarget "sparc-*-*"} mi_clean_restart sparc_register_tests_no_exec -mi_clean_restart $binfile +mi_clean_restart $::testfile mi_runto_main sparc_register_tests diff --git a/gdb/testsuite/gdb.mi/mi-return.exp b/gdb/testsuite/gdb.mi/mi-return.exp index ba296d5c44d..998a1ffbe27 100644 --- a/gdb/testsuite/gdb.mi/mi-return.exp +++ b/gdb/testsuite/gdb.mi/mi-return.exp @@ -31,7 +31,7 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {deb return -1 } -if {[mi_clean_restart $binfile]} { +if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-reverse.exp b/gdb/testsuite/gdb.mi/mi-reverse.exp index d03924078e2..aa252553739 100644 --- a/gdb/testsuite/gdb.mi/mi-reverse.exp +++ b/gdb/testsuite/gdb.mi/mi-reverse.exp @@ -39,7 +39,7 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {deb return -1 } -mi_clean_restart $binfile +mi_clean_restart $::testfile mi_runto_main if [supports_process_record] { diff --git a/gdb/testsuite/gdb.mi/mi-simplerun.exp b/gdb/testsuite/gdb.mi/mi-simplerun.exp index e390f14a00c..5ee7881783a 100644 --- a/gdb/testsuite/gdb.mi/mi-simplerun.exp +++ b/gdb/testsuite/gdb.mi/mi-simplerun.exp @@ -34,7 +34,7 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {deb return -1 } -if {[mi_clean_restart $binfile]} { +if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-solib.exp b/gdb/testsuite/gdb.mi/mi-solib.exp index c66d4b080ad..8ddca8dd0e1 100644 --- a/gdb/testsuite/gdb.mi/mi-solib.exp +++ b/gdb/testsuite/gdb.mi/mi-solib.exp @@ -34,7 +34,7 @@ if { [gdb_compile_shlib ${srcfile_lib} ${binfile_lib} $lib_flags] != "" return -1 } -if {[mi_clean_restart $binfile]} { +if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-stack.exp b/gdb/testsuite/gdb.mi/mi-stack.exp index a91b76e7b04..89f58c8d83b 100644 --- a/gdb/testsuite/gdb.mi/mi-stack.exp +++ b/gdb/testsuite/gdb.mi/mi-stack.exp @@ -32,7 +32,7 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {deb return -1 } -if {[mi_clean_restart $binfile]} { +if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-start.exp b/gdb/testsuite/gdb.mi/mi-start.exp index 745e5c967bf..d384230bf06 100644 --- a/gdb/testsuite/gdb.mi/mi-start.exp +++ b/gdb/testsuite/gdb.mi/mi-start.exp @@ -28,7 +28,7 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {deb return -1 } -if {[mi_clean_restart $binfile]} { +if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-stepi.exp b/gdb/testsuite/gdb.mi/mi-stepi.exp index 8ba63994208..7f53c8b465e 100644 --- a/gdb/testsuite/gdb.mi/mi-stepi.exp +++ b/gdb/testsuite/gdb.mi/mi-stepi.exp @@ -63,7 +63,7 @@ proc test_stepi_nexti {} { } } -mi_clean_restart $binfile +mi_clean_restart $::testfile mi_runto_main test_stepi_nexti diff --git a/gdb/testsuite/gdb.mi/mi-stepn.exp b/gdb/testsuite/gdb.mi/mi-stepn.exp index 489564a0472..f11e9c0882c 100644 --- a/gdb/testsuite/gdb.mi/mi-stepn.exp +++ b/gdb/testsuite/gdb.mi/mi-stepn.exp @@ -26,7 +26,7 @@ if [build_executable ${testfile}.exp ${testfile} ${srcfile} $opts] { return -1 } -mi_clean_restart $binfile +mi_clean_restart $::testfile if {[mi_runto_main] < 0} { return -1 diff --git a/gdb/testsuite/gdb.mi/mi-sym-info.exp b/gdb/testsuite/gdb.mi/mi-sym-info.exp index ef8dd864e27..6b0bf2d6096 100644 --- a/gdb/testsuite/gdb.mi/mi-sym-info.exp +++ b/gdb/testsuite/gdb.mi/mi-sym-info.exp @@ -33,7 +33,7 @@ if {[build_executable "failed to prepare" ${testfile} \ return -1 } -mi_clean_restart $binfile +mi_clean_restart $::testfile # Don't run to main to avoid increasing the search scope to include # debug info of shared libraries like libc, libgcc, etc. diff --git a/gdb/testsuite/gdb.mi/mi-syn-frame.exp b/gdb/testsuite/gdb.mi/mi-syn-frame.exp index 633f317bedc..b3ec3777e1e 100644 --- a/gdb/testsuite/gdb.mi/mi-syn-frame.exp +++ b/gdb/testsuite/gdb.mi/mi-syn-frame.exp @@ -29,7 +29,7 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {deb return -1 } -mi_clean_restart $binfile +mi_clean_restart $::testfile mi_runto_main diff --git a/gdb/testsuite/gdb.mi/mi-thread-bp-deleted.exp b/gdb/testsuite/gdb.mi/mi-thread-bp-deleted.exp index 2a734c8090d..976b68d13f4 100644 --- a/gdb/testsuite/gdb.mi/mi-thread-bp-deleted.exp +++ b/gdb/testsuite/gdb.mi/mi-thread-bp-deleted.exp @@ -47,7 +47,7 @@ foreach_mi_ui_mode mode { save_vars { GDBFLAGS } { append GDBFLAGS " -ex \"maint set target-non-stop on\"" append GDBFLAGS " -ex \"set mi-async on\"" - mi_clean_restart $binfile $start_ops + mi_clean_restart $::testfile $start_ops } mi_runto_main diff --git a/gdb/testsuite/gdb.mi/mi-thread-specific-bp.exp b/gdb/testsuite/gdb.mi/mi-thread-specific-bp.exp index 86d050a570b..81ff2741341 100644 --- a/gdb/testsuite/gdb.mi/mi-thread-specific-bp.exp +++ b/gdb/testsuite/gdb.mi/mi-thread-specific-bp.exp @@ -90,7 +90,7 @@ foreach_mi_ui_mode mode { set start_ops "" } - if {[mi_clean_restart $binfile $start_ops]} { + if {[mi_clean_restart $::testfile $start_ops]} { break } diff --git a/gdb/testsuite/gdb.mi/mi-threads-interrupt.exp b/gdb/testsuite/gdb.mi/mi-threads-interrupt.exp index ff74e7be45e..8aab3b83890 100644 --- a/gdb/testsuite/gdb.mi/mi-threads-interrupt.exp +++ b/gdb/testsuite/gdb.mi/mi-threads-interrupt.exp @@ -33,7 +33,7 @@ proc test_continue_interrupt { } { global binfile global async - if {[mi_clean_restart $binfile]} { + if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-until.exp b/gdb/testsuite/gdb.mi/mi-until.exp index ee50c4f3a4e..e8f24bc7dfe 100644 --- a/gdb/testsuite/gdb.mi/mi-until.exp +++ b/gdb/testsuite/gdb.mi/mi-until.exp @@ -31,7 +31,7 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {deb return -1 } -if {[mi_clean_restart $binfile]} { +if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-var-block.exp b/gdb/testsuite/gdb.mi/mi-var-block.exp index bdba639cff5..3914c3a8dc9 100644 --- a/gdb/testsuite/gdb.mi/mi-var-block.exp +++ b/gdb/testsuite/gdb.mi/mi-var-block.exp @@ -29,7 +29,7 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {deb return -1 } -if {[mi_clean_restart $binfile]} { +if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-var-child-f.exp b/gdb/testsuite/gdb.mi/mi-var-child-f.exp index c424490032a..4856e3d401f 100644 --- a/gdb/testsuite/gdb.mi/mi-var-child-f.exp +++ b/gdb/testsuite/gdb.mi/mi-var-child-f.exp @@ -28,7 +28,7 @@ if {[gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" \ return -1 } -if {[mi_clean_restart $binfile]} { +if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-var-child.exp b/gdb/testsuite/gdb.mi/mi-var-child.exp index 89ce9ddc4e3..4a3ba076db7 100644 --- a/gdb/testsuite/gdb.mi/mi-var-child.exp +++ b/gdb/testsuite/gdb.mi/mi-var-child.exp @@ -29,7 +29,7 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {deb return -1 } -if {[mi_clean_restart $binfile]} { +if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-var-cmd.exp b/gdb/testsuite/gdb.mi/mi-var-cmd.exp index 8c8c3069215..9e7b14c041d 100644 --- a/gdb/testsuite/gdb.mi/mi-var-cmd.exp +++ b/gdb/testsuite/gdb.mi/mi-var-cmd.exp @@ -29,7 +29,7 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {deb return -1 } -if {[mi_clean_restart $binfile]} { +if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-var-cp.exp b/gdb/testsuite/gdb.mi/mi-var-cp.exp index c1d70f135eb..eee10078ebd 100644 --- a/gdb/testsuite/gdb.mi/mi-var-cp.exp +++ b/gdb/testsuite/gdb.mi/mi-var-cp.exp @@ -25,7 +25,7 @@ if {[gdb_compile $srcdir/$subdir/$srcfile $binfile executable {debug c++}] != "" return -1 } -if {[mi_clean_restart $binfile]} { +if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-var-create-rtti.exp b/gdb/testsuite/gdb.mi/mi-var-create-rtti.exp index ad6ce5ccf5e..517449cbe44 100644 --- a/gdb/testsuite/gdb.mi/mi-var-create-rtti.exp +++ b/gdb/testsuite/gdb.mi/mi-var-create-rtti.exp @@ -23,7 +23,7 @@ if [build_executable $testfile.exp $testfile $srcfile $opts] { return -1 } -mi_clean_restart $binfile +mi_clean_restart $::testfile if {[mi_runto_main] < 0} { return -1 diff --git a/gdb/testsuite/gdb.mi/mi-var-display.exp b/gdb/testsuite/gdb.mi/mi-var-display.exp index 553536852f6..3ae593bf4ed 100644 --- a/gdb/testsuite/gdb.mi/mi-var-display.exp +++ b/gdb/testsuite/gdb.mi/mi-var-display.exp @@ -29,7 +29,7 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {deb return -1 } -if {[mi_clean_restart $binfile]} { +if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-var-invalidate.exp b/gdb/testsuite/gdb.mi/mi-var-invalidate.exp index c1c52f2a877..800c22f2c43 100644 --- a/gdb/testsuite/gdb.mi/mi-var-invalidate.exp +++ b/gdb/testsuite/gdb.mi/mi-var-invalidate.exp @@ -44,7 +44,7 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile2}" "${binfile2}" executable {d return -1 } -if {[mi_clean_restart $binfile]} { +if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-var-list-children-invalid-grandchild.exp b/gdb/testsuite/gdb.mi/mi-var-list-children-invalid-grandchild.exp index 0f20c50f238..597e2e0369d 100644 --- a/gdb/testsuite/gdb.mi/mi-var-list-children-invalid-grandchild.exp +++ b/gdb/testsuite/gdb.mi/mi-var-list-children-invalid-grandchild.exp @@ -26,7 +26,7 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {deb return -1 } -if {[mi_clean_restart $binfile]} { +if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-var-rtti.exp b/gdb/testsuite/gdb.mi/mi-var-rtti.exp index fcf84049b6b..c2768b6b7cf 100644 --- a/gdb/testsuite/gdb.mi/mi-var-rtti.exp +++ b/gdb/testsuite/gdb.mi/mi-var-rtti.exp @@ -25,7 +25,7 @@ if [build_executable $testfile.exp $testfile $srcfile $opts] { return -1 } -if {[mi_clean_restart $binfile]} { +if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-vla-c99.exp b/gdb/testsuite/gdb.mi/mi-vla-c99.exp index ec12e6fdbd1..5f23d059d88 100644 --- a/gdb/testsuite/gdb.mi/mi-vla-c99.exp +++ b/gdb/testsuite/gdb.mi/mi-vla-c99.exp @@ -29,7 +29,7 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" \ return -1 } -if {[mi_clean_restart $binfile]} { +if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-vla-fortran.exp b/gdb/testsuite/gdb.mi/mi-vla-fortran.exp index 50770894938..81e2d8963ae 100644 --- a/gdb/testsuite/gdb.mi/mi-vla-fortran.exp +++ b/gdb/testsuite/gdb.mi/mi-vla-fortran.exp @@ -34,7 +34,7 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable \ # the type names can be printed differently. set real [fortran_real4] -if {[mi_clean_restart $binfile]} { +if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi-watch-nonstop.exp b/gdb/testsuite/gdb.mi/mi-watch-nonstop.exp index f9237c0f78c..36d741038aa 100644 --- a/gdb/testsuite/gdb.mi/mi-watch-nonstop.exp +++ b/gdb/testsuite/gdb.mi/mi-watch-nonstop.exp @@ -38,7 +38,7 @@ if {[gdb_compile "$srcdir/$subdir/$srcfile" $binfile executable {debug}] != "" } save_vars { GDBFLAGS } { append GDBFLAGS " -ex \"set non-stop on\"" - mi_clean_restart $binfile + mi_clean_restart $::testfile } mi_gdb_test "-gdb-set mi-async 1" ".*" diff --git a/gdb/testsuite/gdb.mi/mi-watch.exp b/gdb/testsuite/gdb.mi/mi-watch.exp index e318a2b3e47..43f23786aa2 100644 --- a/gdb/testsuite/gdb.mi/mi-watch.exp +++ b/gdb/testsuite/gdb.mi/mi-watch.exp @@ -155,7 +155,7 @@ proc test_watchpoint_all {mi_mode type} { } else { set start_ops "" } - if [mi_clean_restart ${binfile} $start_ops] { + if [mi_clean_restart ${::testfile} $start_ops] { return } diff --git a/gdb/testsuite/gdb.mi/mi2-amd64-entry-value.exp b/gdb/testsuite/gdb.mi/mi2-amd64-entry-value.exp index c7e21e9f4c8..0d51dc5b867 100644 --- a/gdb/testsuite/gdb.mi/mi2-amd64-entry-value.exp +++ b/gdb/testsuite/gdb.mi/mi2-amd64-entry-value.exp @@ -31,7 +31,7 @@ if [build_executable ${testfile}.exp ${binfile} ${srcfile} $opts] { return -1 } -if {[mi_clean_restart $binfile]} { +if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi2-cli-display.exp b/gdb/testsuite/gdb.mi/mi2-cli-display.exp index 656c93e4827..993b87cb376 100644 --- a/gdb/testsuite/gdb.mi/mi2-cli-display.exp +++ b/gdb/testsuite/gdb.mi/mi2-cli-display.exp @@ -25,7 +25,7 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {deb return -1 } -if {[mi_clean_restart $binfile]} { +if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/mi2-var-child.exp b/gdb/testsuite/gdb.mi/mi2-var-child.exp index 9bd90548708..3618d5a756c 100644 --- a/gdb/testsuite/gdb.mi/mi2-var-child.exp +++ b/gdb/testsuite/gdb.mi/mi2-var-child.exp @@ -29,7 +29,7 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {deb return -1 } -if {[mi_clean_restart $binfile]} { +if {[mi_clean_restart $::testfile]} { return } diff --git a/gdb/testsuite/gdb.mi/new-ui-mi-sync.exp b/gdb/testsuite/gdb.mi/new-ui-mi-sync.exp index cb83329c5a9..7112248f6f2 100644 --- a/gdb/testsuite/gdb.mi/new-ui-mi-sync.exp +++ b/gdb/testsuite/gdb.mi/new-ui-mi-sync.exp @@ -102,7 +102,7 @@ proc do_test {sync_command} { } foreach_with_prefix sync-command {"run" "continue"} { - if {[mi_clean_restart $binfile "separate-mi-tty"] != 0} { + if {[mi_clean_restart $::testfile "separate-mi-tty"] != 0} { fail "could not start gdb" break } diff --git a/gdb/testsuite/gdb.mi/pr11022.exp b/gdb/testsuite/gdb.mi/pr11022.exp index ad8e3b2dd48..1e01bf623f9 100644 --- a/gdb/testsuite/gdb.mi/pr11022.exp +++ b/gdb/testsuite/gdb.mi/pr11022.exp @@ -29,7 +29,7 @@ proc test_memory_changed_observer { mi_command } { with_test_prefix "${mi_command}" { global srcfile binfile - mi_clean_restart $binfile + mi_clean_restart $::testfile mi_runto_main set line_number [gdb_get_line_number "break here"] diff --git a/gdb/testsuite/gdb.mi/print-simple-values.exp b/gdb/testsuite/gdb.mi/print-simple-values.exp index 1c56d681966..23488e35e9e 100644 --- a/gdb/testsuite/gdb.mi/print-simple-values.exp +++ b/gdb/testsuite/gdb.mi/print-simple-values.exp @@ -34,7 +34,7 @@ if [build_executable "failed to prepare" $testfile $srcfile $opts] { return -1 } -if [mi_clean_restart $binfile] { +if [mi_clean_restart $::testfile] { return } diff --git a/gdb/testsuite/gdb.mi/run-with-two-mi-uis.exp b/gdb/testsuite/gdb.mi/run-with-two-mi-uis.exp index df370c98b2d..c9e352df40a 100644 --- a/gdb/testsuite/gdb.mi/run-with-two-mi-uis.exp +++ b/gdb/testsuite/gdb.mi/run-with-two-mi-uis.exp @@ -29,7 +29,7 @@ if {[build_executable $testfile.exp $testfile ${srcfile} "debug"] == -1} { # UI_TO_RUN is the UI that should issue the run command. proc do_test { ui_to_run } { - if {[mi_clean_restart $::binfile "separate-mi-tty"] != 0} { + if {[mi_clean_restart $::testfile "separate-mi-tty"] != 0} { fail "could not start gdb" return } diff --git a/gdb/testsuite/gdb.mi/user-selected-context-sync.exp b/gdb/testsuite/gdb.mi/user-selected-context-sync.exp index f85e108ab19..a0bf11f2f22 100644 --- a/gdb/testsuite/gdb.mi/user-selected-context-sync.exp +++ b/gdb/testsuite/gdb.mi/user-selected-context-sync.exp @@ -1329,7 +1329,7 @@ foreach_with_prefix mode { "all-stop" "non-stop" } { set GDBFLAGS [concat $GDBFLAGS " -ex \"set non-stop 1\""] } - if { [mi_clean_restart $binfile "separate-mi-tty"] != 0 } { + if { [mi_clean_restart $::testfile "separate-mi-tty"] != 0 } { break } }