OLD | NEW |
1 # Copyright 2009-2012 Free Software Foundation, Inc. | 1 # Copyright 2009-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 21 matching lines...) Expand all Loading... |
32 set MIFLAGS "-i=mi" | 32 set MIFLAGS "-i=mi" |
33 | 33 |
34 gdb_exit | 34 gdb_exit |
35 if {[mi_gdb_start]} { | 35 if {[mi_gdb_start]} { |
36 continue | 36 continue |
37 } | 37 } |
38 | 38 |
39 # | 39 # |
40 # Start here | 40 # Start here |
41 # | 41 # |
42 set testfile "nsthrexec" | 42 standard_testfile nsthrexec.c |
43 set srcfile "$testfile.c" | |
44 set binfile "$objdir/$subdir/mi-$testfile" | |
45 | 43 |
46 set options [list debug incdir=$objdir] | 44 set options [list debug] |
47 if {[gdb_compile_pthreads "$srcdir/$subdir/$srcfile" $binfile executable $option
s] != "" } { | 45 if {[gdb_compile_pthreads "$srcdir/$subdir/$srcfile" $binfile executable $option
s] != "" } { |
48 return -1 | 46 return -1 |
49 } | 47 } |
50 | 48 |
51 mi_gdb_reinitialize_dir $srcdir/$subdir | 49 mi_gdb_reinitialize_dir $srcdir/$subdir |
52 mi_gdb_load $binfile | 50 mi_gdb_load $binfile |
53 | 51 |
54 mi_gdb_test "-gdb-set non-stop 1" ".*" | 52 mi_gdb_test "-gdb-set non-stop 1" ".*" |
55 mi_gdb_test "-gdb-set target-async 1" ".*" | 53 mi_gdb_test "-gdb-set target-async 1" ".*" |
56 mi_detect_async | 54 mi_detect_async |
(...skipping 27 matching lines...) Expand all Loading... |
84 | 82 |
85 # Now resume the execler thread. Eventually, it execs. | 83 # Now resume the execler thread. Eventually, it execs. |
86 mi_send_resuming_command "exec-continue --thread 2" "resume execler thread" | 84 mi_send_resuming_command "exec-continue --thread 2" "resume execler thread" |
87 | 85 |
88 # Check that the main thread passes by the _dl_debug_state internal | 86 # Check that the main thread passes by the _dl_debug_state internal |
89 # breakpoint without silently stopping. | 87 # breakpoint without silently stopping. |
90 mi_expect_stop "breakpoint-hit" "main" "\[^\n\]*" "$srcfile" \ | 88 mi_expect_stop "breakpoint-hit" "main" "\[^\n\]*" "$srcfile" \ |
91 "\[0-9\]*" {"" "disp=\"keep\""} "stop at main after exec" | 89 "\[0-9\]*" {"" "disp=\"keep\""} "stop at main after exec" |
92 | 90 |
93 mi_gdb_exit | 91 mi_gdb_exit |
OLD | NEW |