Automatic Copyright Year update after running gdb/copyright.py
[deliverable/binutils-gdb.git] / gdb / testsuite / gdb.arch / aarch64-dbreg-contents.exp
CommitLineData
88b9d363 1# Copyright 2019-2022 Free Software Foundation, Inc.
01c7ae81
WP
2
3# This program is free software; you can redistribute it and/or modify
4# it under the terms of the GNU General Public License as published by
5# the Free Software Foundation; either version 3 of the License, or
6# (at your option) any later version.
7#
8# This program is distributed in the hope that it will be useful,
9# but WITHOUT ANY WARRANTY; without even the implied warranty of
10# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11# GNU General Public License for more details.
12#
13# You should have received a copy of the GNU General Public License
14# along with this program. If not, see <http://www.gnu.org/licenses/>.
15#
16# Make sure that the inferior doesn't assert and exits successfully.
17#
18# This test checks that GDB does not alter watchpoints set by an inferior.
19# It sets a watchpoint on memory then writes to the watched memory.
9d70ffbc 20# It will exit with 2 if the watchpoint is not reached.
01c7ae81
WP
21#
22# See PR breakpoints/21870.
23
24if {![is_aarch64_target]} {
25 verbose "Skipping ${gdb_test_file_name}."
26 return
27}
28
29standard_testfile .c
30
9d70ffbc
WP
31if { [prepare_for_testing "failed to prepare" ${testfile}] } {
32 return
01c7ae81
WP
33}
34
9d70ffbc
WP
35runto_main
36set test "continue to exit"
37gdb_test_multiple "continue" "$test" {
01c7ae81 38 -re "exited with code 01.*$gdb_prompt $" {
9d70ffbc 39 # For case that the PTRACE_SETREGSET call fails.
01c7ae81
WP
40 pass "$test"
41 }
42 -re "exited normally.*$gdb_prompt $" {
43 pass "$test"
44 }
45}
This page took 0.628163 seconds and 4 git commands to generate.