mirror of
https://github.com/espressif/binutils-gdb.git
synced 2025-06-22 02:50:08 +08:00
* lib/mi-support.exp: (mi_run_to_main): Allow anything to precede
regexp for stopping at main. Could have multiple event notifications. Don't assume that main was declared with no parameters. (mi_next): Use mi_step_to. (mi_step): Use mi_next_to.
This commit is contained in:
@ -1,3 +1,11 @@
|
|||||||
|
2002-09-10 Keith Seitz <keiths@redhat.com>
|
||||||
|
|
||||||
|
* lib/mi-support.exp: (mi_run_to_main): Allow anything to precede
|
||||||
|
regexp for stopping at main. Could have multiple event notifications.
|
||||||
|
Don't assume that main was declared with no parameters.
|
||||||
|
(mi_next): Use mi_step_to.
|
||||||
|
(mi_step): Use mi_next_to.
|
||||||
|
|
||||||
2002-09-09 Corinna Vinschen <vinschen@redhat.com>
|
2002-09-09 Corinna Vinschen <vinschen@redhat.com>
|
||||||
|
|
||||||
* gdb.base/default.exp: Fix expected string in `info float' test.
|
* gdb.base/default.exp: Fix expected string in `info float' test.
|
||||||
|
@ -656,46 +656,18 @@ proc mi_run_to_main { } {
|
|||||||
|
|
||||||
|
|
||||||
# Next to the next statement
|
# Next to the next statement
|
||||||
|
# For return values, see mi_run_to_helper
|
||||||
|
|
||||||
proc mi_next { test } {
|
proc mi_next { test } {
|
||||||
global suppress_flag
|
return [mi_next_to {.*} {.*} {.*} {.*} $test]
|
||||||
if { $suppress_flag } {
|
|
||||||
return -1
|
|
||||||
}
|
|
||||||
global mi_gdb_prompt
|
|
||||||
send_gdb "220-exec-next\n"
|
|
||||||
gdb_expect {
|
|
||||||
-re "220\\^running\r\n${mi_gdb_prompt}220\\*stopped,reason=\"end-stepping-range\",thread-id=\"$decimal\",frame=\{addr=\"$hex\",func=\".*\",args=\[\\\[\{].*[\\\]\}\],file=\".*\",line=\"\[0-9\]*\"\}\r\n$mi_gdb_prompt$" {
|
|
||||||
pass "$test"
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
timeout {
|
|
||||||
fail "$test"
|
|
||||||
return -1
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
# Step to the next statement
|
# Step to the next statement
|
||||||
|
# For return values, see mi_run_to_helper
|
||||||
|
|
||||||
proc mi_step { test } {
|
proc mi_step { test } {
|
||||||
global suppress_flag
|
return [mi_step_to {.*} {.*} {.*} {.*} $test]
|
||||||
if { $suppress_flag } {
|
|
||||||
return -1
|
|
||||||
}
|
|
||||||
global mi_gdb_prompt
|
|
||||||
send_gdb "220-exec-step\n"
|
|
||||||
gdb_expect {
|
|
||||||
-re "220\\^running\r\n${mi_gdb_prompt}220\\*stopped,reason=\"end-stepping-range\",thread-id=\"$decimal\",frame=\{addr=\"$hex\",func=\".*\",args=\[\\\[\{\].*\[\\\]\}\],file=\".*\",line=\"\[0-9\]*\"\}\r\n$mi_gdb_prompt$" {
|
|
||||||
pass "$test"
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
timeout {
|
|
||||||
fail "$test"
|
|
||||||
return -1
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
# cmd should not include the number or newline (i.e. "exec-step 3", not
|
# cmd should not include the number or newline (i.e. "exec-step 3", not
|
||||||
@ -714,11 +686,11 @@ proc mi_run_to_helper { cmd reason func args file line extra test } {
|
|||||||
global decimal
|
global decimal
|
||||||
send_gdb "220-$cmd\n"
|
send_gdb "220-$cmd\n"
|
||||||
gdb_expect {
|
gdb_expect {
|
||||||
-re "220\\^running\r\n${mi_gdb_prompt}220\\*stopped,reason=\"$reason\",thread-id=\"$decimal\",frame=\{addr=\"$hex\",func=\"$func\",args=$args,file=\".*$file\",line=\"$line\"\}$extra\r\n$mi_gdb_prompt$" {
|
-re ".*220\\^running\r\n${mi_gdb_prompt}.*220\\*stopped,reason=\"$reason\",thread-id=\"$decimal\",frame=\{addr=\"$hex\",func=\"$func\",args=$args,file=\".*$file\",line=\"$line\"\}$extra\r\n$mi_gdb_prompt$" {
|
||||||
pass "$test"
|
pass "$test"
|
||||||
return 0
|
return 0
|
||||||
}
|
}
|
||||||
-re "220\\^running\r\n${mi_gdb_prompt}220\\*stopped,reason=\"$reason\",thread-id=\"$decimal\",frame=\{addr=\"$hex\",func=\".*\",args=\[\\\[\{\].*\[\\\]\}\],file=\".*\",line=\"\[0-9\]*\"\}.*\r\n$mi_gdb_prompt$" {
|
-re ".*220\\^running\r\n${mi_gdb_prompt}.*220\\*stopped,reason=\"$reason\",thread-id=\"$decimal\",frame=\{addr=\"$hex\",func=\".*\",args=\[\\\[\{\].*\[\\\]\}\],file=\".*\",line=\"\[0-9\]*\"\}.*\r\n$mi_gdb_prompt$" {
|
||||||
fail "$test (stopped at wrong place)"
|
fail "$test (stopped at wrong place)"
|
||||||
return -1
|
return -1
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user