| OLD | NEW |
| 1 # Copyright 1999, 2001, 2004, 2006-2012 Free Software Foundation, Inc. | 1 # Copyright 1999, 2001, 2004, 2006-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 |
| (...skipping 14 matching lines...) Expand all Loading... |
| 25 # | 25 # |
| 26 | 26 |
| 27 load_lib mi-support.exp | 27 load_lib mi-support.exp |
| 28 set MIFLAGS "-i=mi" | 28 set MIFLAGS "-i=mi" |
| 29 | 29 |
| 30 gdb_exit | 30 gdb_exit |
| 31 if [mi_gdb_start] { | 31 if [mi_gdb_start] { |
| 32 continue | 32 continue |
| 33 } | 33 } |
| 34 | 34 |
| 35 set testfile "basics" | 35 standard_testfile basics.c |
| 36 set srcfile ${testfile}.c | 36 |
| 37 set binfile ${objdir}/${subdir}/mi-break | 37 if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {deb
ug}] != "" } { |
| 38 if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {deb
ug additional_flags=-DFAKEARGV}] != "" } { | |
| 39 untested mi-break.exp | 38 untested mi-break.exp |
| 40 return -1 | 39 return -1 |
| 41 } | 40 } |
| 42 | 41 |
| 43 mi_delete_breakpoints | 42 mi_delete_breakpoints |
| 44 mi_gdb_reinitialize_dir $srcdir/$subdir | 43 mi_gdb_reinitialize_dir $srcdir/$subdir |
| 45 mi_gdb_load ${binfile} | 44 mi_gdb_load ${binfile} |
| 46 | 45 |
| 47 # Locate line numbers in basics.c. | 46 # Locate line numbers in basics.c. |
| 48 set line_callee4_head [gdb_get_line_number "callee4 ("] | 47 set line_callee4_head [gdb_get_line_number "callee4 ("] |
| (...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 114 | 113 |
| 115 # Insert some breakpoints and list them | 114 # Insert some breakpoints and list them |
| 116 # Also, disable some so they do not interfere with other tests | 115 # Also, disable some so they do not interfere with other tests |
| 117 # Tests: | 116 # Tests: |
| 118 # -break-insert -r main | 117 # -break-insert -r main |
| 119 # -break-insert -r callee2 | 118 # -break-insert -r callee2 |
| 120 # -break-insert -r callee | 119 # -break-insert -r callee |
| 121 # -break-insert -r .*llee | 120 # -break-insert -r .*llee |
| 122 # -break-list | 121 # -break-list |
| 123 | 122 |
| 124 setup_xfail "*-*-*" | 123 setup_kfail "*-*-*" mi/14270 |
| 125 mi_gdb_test "122-break-insert -r main" \ | 124 mi_gdb_test "122-break-insert -r main" \ |
| 126 "122\\^done,bkpt=\{number=\"5\",addr=\"$hex\",file=\".*basics.c\",l
ine=\"$line_main_body\"\}" \ | 125 "122\\^done,bkpt=\{number=\"5\",addr=\"$hex\",file=\".*basics.c\",l
ine=\"$line_main_body\"\}" \ |
| 127 "break-insert -r operation" | 126 "break-insert -r operation" |
| 128 | 127 |
| 129 setup_xfail "*-*-*" | 128 setup_kfail "*-*-*" mi/14270 |
| 130 mi_gdb_test "133-break-insert -r callee2" \ | 129 mi_gdb_test "133-break-insert -r callee2" \ |
| 131 "133\\^done,bkpt=\{number=\"6\",addr=\"$hex\",file=\".*basics.c\",l
ine=\"$line_callee2_body\"\}" \ | 130 "133\\^done,bkpt=\{number=\"6\",addr=\"$hex\",file=\".*basics.c\",l
ine=\"$line_callee2_body\"\}" \ |
| 132 "insert breakpoint with regexp callee2" | 131 "insert breakpoint with regexp callee2" |
| 133 | 132 |
| 134 setup_xfail "*-*-*" | 133 setup_kfail "*-*-*" mi/14270 |
| 135 mi_gdb_test "144-break-insert -r callee" \ | 134 mi_gdb_test "144-break-insert -r callee" \ |
| 136 "144\\^done,bkpt=\{number=\"7\",addr=\"$hex\",file=\".*basics.c\",li
ne=\"$line_callee1_body\"\},bkpt=\{number=\"8\",addr=\"$hex\",file=\".*basics.c\
",line=\"$line_callee2_body\"\},bkpt=\{number=\"9\",addr=\"$hex\",file=\".*basic
s.c\",line=\"$line_callee3_body\"\},bkpt=\{number=\"10\",addr=\"$hex\",file=\".*
basics.c\",line=\"$line_callee4_body\"\}" \ | 135 "144\\^done,bkpt=\{number=\"7\",addr=\"$hex\",file=\".*basics.c\",li
ne=\"$line_callee1_body\"\},bkpt=\{number=\"8\",addr=\"$hex\",file=\".*basics.c\
",line=\"$line_callee2_body\"\},bkpt=\{number=\"9\",addr=\"$hex\",file=\".*basic
s.c\",line=\"$line_callee3_body\"\},bkpt=\{number=\"10\",addr=\"$hex\",file=\".*
basics.c\",line=\"$line_callee4_body\"\}" \ |
| 137 "insert breakpoint with regexp callee" | 136 "insert breakpoint with regexp callee" |
| 138 | 137 |
| 139 setup_xfail "*-*-*" | 138 setup_kfail "*-*-*" mi/14270 |
| 140 mi_gdb_test "155-break-insert -r \.\*llee" \ | 139 mi_gdb_test "155-break-insert -r \.\*llee" \ |
| 141 "155\\^done,bkpt=\{number=\"11\",addr=\"$hex\",file=\".*basics.c\",l
ine=\"$line_callee1_body\"\},bkpt=\{number=\"12\",addr=\"$hex\",file=\".*basics.
c\",line=\"$line_callee2_body\"\},bkpt=\{number=\"13\",addr=\"$hex\",file=\".*ba
sics.c\",line=\"$line_callee3_body\"\},bkpt=\{number=\"14\",addr=\"$hex\",file=\
".*basics.c\",line=\"$line_callee4_body\"\}" \ | 140 "155\\^done,bkpt=\{number=\"11\",addr=\"$hex\",file=\".*basics.c\",l
ine=\"$line_callee1_body\"\},bkpt=\{number=\"12\",addr=\"$hex\",file=\".*basics.
c\",line=\"$line_callee2_body\"\},bkpt=\{number=\"13\",addr=\"$hex\",file=\".*ba
sics.c\",line=\"$line_callee3_body\"\},bkpt=\{number=\"14\",addr=\"$hex\",file=\
".*basics.c\",line=\"$line_callee4_body\"\}" \ |
| 142 "insert breakpoint with regexp .*llee" | 141 "insert breakpoint with regexp .*llee" |
| 143 | 142 |
| 144 setup_xfail "*-*-*" | 143 setup_kfail "*-*-*" mi/14270 |
| 145 mi_gdb_test "166-break-list" \ | 144 mi_gdb_test "166-break-list" \ |
| 146 "1\\\^done,BreakpointTable=\{nr_rows=\".\",nr_cols=\".\",hdr=\\\[\{w
idth=\".*\",alignment=\".*\",col_name=\"number\",colhdr=\"Num\"\}.*colhdr=\"Type
\".*colhdr=\"Disp\".*colhdr=\"Enb\".*colhdr=\"Address\".*colhdr=\"What\".*\\\],b
ody=\\\[bkpt=\{number=\"5\",type=\"breakpoint\",disp=\"keep\",enabled=\"y\",addr
=\"$hex\",func=\"main\",file=\".*basics.c\",line=\"$line_main_body\",times=\"0\"
\},.*\}\\\]\}" \ | 145 "1\\\^done,BreakpointTable=\{nr_rows=\".\",nr_cols=\".\",hdr=\\\[\{w
idth=\".*\",alignment=\".*\",col_name=\"number\",colhdr=\"Num\"\}.*colhdr=\"Type
\".*colhdr=\"Disp\".*colhdr=\"Enb\".*colhdr=\"Address\".*colhdr=\"What\".*\\\],b
ody=\\\[bkpt=\{number=\"5\",type=\"breakpoint\",disp=\"keep\",enabled=\"y\",addr
=\"$hex\",func=\"main\",file=\".*basics.c\",line=\"$line_main_body\",times=\"0\"
\},.*\}\\\]\}" \ |
| 147 "list of breakpoints" | 146 "list of breakpoints" |
| 148 | 147 |
| 149 mi_gdb_test "177-break-delete" \ | 148 mi_gdb_test "177-break-delete" \ |
| 150 "177\\^done" \ | 149 "177\\^done" \ |
| 151 "delete temp breakpoints" | 150 "delete temp breakpoints" |
| 152 } | 151 } |
| 153 | 152 |
| 154 proc test_ignore_count {} { | 153 proc test_ignore_count {} { |
| (...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 252 test_ignore_count | 251 test_ignore_count |
| 253 | 252 |
| 254 test_error | 253 test_error |
| 255 | 254 |
| 256 test_disabled_creation | 255 test_disabled_creation |
| 257 | 256 |
| 258 test_breakpoint_commands | 257 test_breakpoint_commands |
| 259 | 258 |
| 260 mi_gdb_exit | 259 mi_gdb_exit |
| 261 return 0 | 260 return 0 |
| OLD | NEW |