-# Copyright 1988-2015 Free Software Foundation, Inc.
+# Copyright 1988-2020 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 number available.
-if { [prepare_for_testing hbreak2.exp "hbreak2" {break.c break1.c} {debug nowarnings}] } {
+if { [prepare_for_testing "failed to prepare" "hbreak2" {break.c break1.c} {debug nowarnings}] } {
return -1
}
set srcfile break.c
"thread-specific hardware breakpoint on non-existent thread disallowed"
gdb_test "hbreak $bp_location12 thread foo" \
- "Junk after thread keyword.*" \
+ "Invalid thread ID: foo" \
"thread-specific hardware breakpoint on bogus thread ID disallowed"
# Verify that GDB responds gracefully to a breakpoint command with
# As long as we're stopped (breakpointed) in a called function,
# verify that we can successfully backtrace & such from here.
-#
-# In this and the following test, the _sr4export check apparently is needed
-# for hppa*-*-hpux.
-#
-gdb_test_multiple "bt" "backtrace while in called function" {
- -re "#0\[ \t\]*($hex in )?marker2.*:$bp_location8\r\n#1.*_sr4export.*$gdb_prompt $" {
- pass "backtrace while in called function"
- }
- -re "#0\[ \t\]*($hex in )?marker2.*:$bp_location8\r\n#1.*function called from gdb.*$gdb_prompt $" {
- pass "backtrace while in called function"
- }
-}
+gdb_test "bt" \
+ "#0\[ \t\]*($hex in )?marker2.*:$bp_location8\r\n#1\[ \t\]*<function called from gdb>.*" \
+ "backtrace while in called function"
# Return from the called function. For remote targets, it's important to do
# this before runto_main, which otherwise may silently stop on the dummy
# breakpoint inserted by GDB at the program's entry point.
#
gdb_test_multiple "finish" "finish from called function" {
- -re "Run till exit from .*marker2.* at .*$bp_location8\r\n.* in _sr4export.*$gdb_prompt $" {
- pass "finish from called function"
- }
-re "Run till exit from .*marker2.* at .*$bp_location8\r\n.*function called from gdb.*$gdb_prompt $" {
pass "finish from called function"
}
# Build a new file with optimization enabled so that we can try breakpoints
# on targets with optimized prologues.
-if { [prepare_for_testing hbreak2.exp "hbreak2o2" {break.c break1.c} {debug nowarnings optimize=-O2}] } {
+if { [prepare_for_testing "failed to prepare" "hbreak2o2" {break.c break1.c} {debug nowarnings optimize=-O2}] } {
return -1
}