OLD | NEW |
1 # Copyright 2002-2003, 2005, 2007-2012 Free Software Foundation, Inc. | 1 # Copyright 2002-2003, 2005, 2007-2012 Free Software Foundation, Inc. |
2 | 2 |
3 # This program is free software; you can redistribute it and/or modify | 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 | 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 | 5 # the Free Software Foundation; either version 3 of the License, or |
6 # (at your option) any later version. | 6 # (at your option) any later version. |
7 # | 7 # |
8 # This program is distributed in the hope that it will be useful, | 8 # This program is distributed in the hope that it will be useful, |
9 # but WITHOUT ANY WARRANTY; without even the implied warranty of | 9 # but WITHOUT ANY WARRANTY; without even the implied warranty of |
10 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | 10 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
11 # GNU General Public License for more details. | 11 # GNU General Public License for more details. |
12 # | 12 # |
13 # You should have received a copy of the GNU General Public License | 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/>. | 14 # along with this program. If not, see <http://www.gnu.org/licenses/>. |
15 | 15 |
16 # Test MI output with synthetic frames on the stack (call dummies, | 16 # Test MI output with synthetic frames on the stack (call dummies, |
17 # signal handlers). | 17 # signal handlers). |
18 | 18 |
19 if [target_info exists gdb,nosignals] { | 19 if [target_info exists gdb,nosignals] { |
20 verbose "Skipping mi-syn-frame.exp because of nosignals." | 20 verbose "Skipping mi-syn-frame.exp because of nosignals." |
21 continue | 21 continue |
22 } | 22 } |
23 | 23 |
24 load_lib mi-support.exp | 24 load_lib mi-support.exp |
25 set MIFLAGS "-i=mi" | 25 set MIFLAGS "-i=mi" |
26 | 26 |
27 set testfile "mi-syn-frame" | 27 standard_testfile |
28 set srcfile ${testfile}.c | 28 |
29 set binfile ${objdir}/${subdir}/${testfile} | 29 if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {deb
ug}] != "" } { |
30 if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {deb
ug additional_flags=-DFAKEARGV}] != "" } { | |
31 untested mi-syn-frame.exp | 30 untested mi-syn-frame.exp |
32 return -1 | 31 return -1 |
33 } | 32 } |
34 | 33 |
35 mi_gdb_exit | 34 mi_gdb_exit |
36 mi_gdb_start | 35 mi_gdb_start |
37 mi_run_to_main | 36 mi_run_to_main |
38 | 37 |
39 mi_create_breakpoint "foo" 2 keep foo ".*mi-syn-frame.c" $decimal $hex \ | 38 mi_create_breakpoint "foo" 2 keep foo ".*mi-syn-frame.c" $decimal $hex \ |
40 "insert breakpoint foo" | 39 "insert breakpoint foo" |
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
94 | 93 |
95 mi_gdb_test "410-data-evaluate-expression bar()" \ | 94 mi_gdb_test "410-data-evaluate-expression bar()" \ |
96 ".*410\\^error,msg=\"The program being debugged was signaled while in a functi
on called from GDB.\\\\nGDB remains in the frame where the signal was received.\
\\\nTo change this behavior use \\\\\"set unwindonsignal on\\\\\".\\\\nEvaluatio
n of the expression containing the function\\\\n\\(bar\\) will be abandoned.\\\\
nWhen the function is done executing, GDB will silently stop.\"" \ | 95 ".*410\\^error,msg=\"The program being debugged was signaled while in a functi
on called from GDB.\\\\nGDB remains in the frame where the signal was received.\
\\\nTo change this behavior use \\\\\"set unwindonsignal on\\\\\".\\\\nEvaluatio
n of the expression containing the function\\\\n\\(bar\\) will be abandoned.\\\\
nWhen the function is done executing, GDB will silently stop.\"" \ |
97 "call inferior function which raises exception" | 96 "call inferior function which raises exception" |
98 | 97 |
99 mi_gdb_test "411-stack-list-frames" "411\\^done,stack=\\\[frame=\{level=\"0\",ad
dr=\"$hex\",func=\"bar\",file=\".*mi-syn-frame.c\",fullname=\"${fullname_syntax}
${srcfile}\",line=\"$decimal\"},frame=\{level=\"1\",addr=\"$hex\",func=\"<functi
on called from gdb>\"\},frame=\{level=\"2\",addr=\"$hex\",func=\"main\",file=\".
*mi-syn-frame.c\",fullname=\"${fullname_syntax}${srcfile}\",line=\"$decimal\"}.*
\\\]" "backtrace from inferior function at exception" | 98 mi_gdb_test "411-stack-list-frames" "411\\^done,stack=\\\[frame=\{level=\"0\",ad
dr=\"$hex\",func=\"bar\",file=\".*mi-syn-frame.c\",fullname=\"${fullname_syntax}
${srcfile}\",line=\"$decimal\"},frame=\{level=\"1\",addr=\"$hex\",func=\"<functi
on called from gdb>\"\},frame=\{level=\"2\",addr=\"$hex\",func=\"main\",file=\".
*mi-syn-frame.c\",fullname=\"${fullname_syntax}${srcfile}\",line=\"$decimal\"}.*
\\\]" "backtrace from inferior function at exception" |
100 | 99 |
101 mi_gdb_exit | 100 mi_gdb_exit |
102 | 101 |
103 return 0 | 102 return 0 |
OLD | NEW |