summaryrefslogtreecommitdiff
path: root/gdb/testsuite/gdb.threads/watchthreads2.exp
diff options
context:
space:
mode:
Diffstat (limited to 'gdb/testsuite/gdb.threads/watchthreads2.exp')
-rw-r--r--gdb/testsuite/gdb.threads/watchthreads2.exp11
1 files changed, 3 insertions, 8 deletions
diff --git a/gdb/testsuite/gdb.threads/watchthreads2.exp b/gdb/testsuite/gdb.threads/watchthreads2.exp
index aaa3430715d..d67b9f094ed 100644
--- a/gdb/testsuite/gdb.threads/watchthreads2.exp
+++ b/gdb/testsuite/gdb.threads/watchthreads2.exp
@@ -28,17 +28,12 @@ if {[skip_hw_watchpoint_tests]} {
return 0
}
-set testfile "watchthreads2"
-set srcfile ${testfile}.c
-set binfile ${objdir}/${subdir}/${testfile}
-if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable [list debug "incdir=${objdir}" "additional_flags=-DNR_THREADS=$NR_THREADS -DX_INCR_COUNT=$X_INCR_COUNT"]] != "" } {
+standard_testfile
+if {[gdb_compile_pthreads "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable [list debug "additional_flags=-DNR_THREADS=$NR_THREADS -DX_INCR_COUNT=$X_INCR_COUNT"]] != "" } {
return -1
}
-gdb_exit
-gdb_start
-gdb_reinitialize_dir $srcdir/$subdir
-gdb_load ${binfile}
+clean_restart ${binfile}
gdb_test_no_output "set can-use-hw-watchpoints 1" ""