diff options
author | Vladimir Prus <vladimir@codesourcery.com> | 2011-04-27 10:17:39 +0000 |
---|---|---|
committer | Vladimir Prus <vladimir@codesourcery.com> | 2011-04-27 10:17:39 +0000 |
commit | 8d3788bd590aa066f4f8383b7f8da20211e4ea9e (patch) | |
tree | 70a6d9187ed169486305055cf406ee9d0a79c08f /gdb/testsuite/lib | |
parent | b4e7b88557a669c6a400014f406fcf5a5abb5290 (diff) | |
download | gdb-8d3788bd590aa066f4f8383b7f8da20211e4ea9e.zip gdb-8d3788bd590aa066f4f8383b7f8da20211e4ea9e.tar.gz gdb-8d3788bd590aa066f4f8383b7f8da20211e4ea9e.tar.bz2 |
MI breakpoint notifications.
* annotate.c (breakpoint_changed): Adjust parameter type.
* breakpoint.c (set_breakpoint_condition): Adjust to change
in breakpoint_modified type.
(breakpoint_set_commands): Likewise.
(do_map_commands_command): Likewise.
(bpstat_check_breakpoint_conditions): Notify that breakpoint has
changed after bumping hit count.
(bpstat_stop_status): Likewise.
(print_one_breakpoint_location): Don't wrap in tuple here.
(print_one_breakpoint): Always print individual locations.
For locations, use unnamed tuple.
(disable_breakpoints_in_unloaded_shlib): Notify that breakpoint
has changed.
(create_catchpoint, create_syscall_event_catchpoint): Call
breakpoint_created obsever.
(mention): Don't call breakpoint_created observer.
(create_breakpoint_sal): Call breakpoint_created observer.
(create_breakpoint, watch_command_1): Likewise.
(create_ada_exception_breakpoint): Likewise.
(delete_breakpoint): Call breakpoint_deleted breakpoint.
(locations_are_equal): New.
(update_breakpoint_locations): If locations were changed, notify.
(set_ignore_count, disable_breakpoint, do_enable_breakpoint):
Call breakpoint_modified observer.
* mi/mi-cmd-break.c (breakpoint_notify): Adjust.
(mi_cmd_break_insert): Don't set observers for modify and delete.
* mi/mi-interp.c (mi_suppress_breakpoint_notifications): New.
(mi_breakpoint_created, mi_breakpoint_deleted)
(mi_breakpoint_modified): New.
(mi_interpreter_init): Hook the above.
* mi/mi-main.c (mi_cmd_execute): Disable breakpoint notifications
while -break-* commands are executing.
* mi/mi-main.h (mi_suppress_breakpoint_notifications): New.
* mi/mi-out.c (struct ui_out_data): New field original_buffer.
(mi_redirect): New.
(mi_ui_out_impl): Hook in mi_redirect.
(mi_field_skip): True to the name, skip the field, don't output
a field with an empty value.
* python/py-breakpoint.c (gdbpy_breakpoint_created)
(gdbpy_breakpoint_deleted): Adjust.
* tui/tui-hooks.c (tui_event_create_breakpoint)
(tui_event_delete_breakpoint, tui_event_modify_breakpoint): Adjust.
Diffstat (limited to 'gdb/testsuite/lib')
-rw-r--r-- | gdb/testsuite/lib/mi-support.exp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/gdb/testsuite/lib/mi-support.exp b/gdb/testsuite/lib/mi-support.exp index e75a4f5..e3f6b03 100644 --- a/gdb/testsuite/lib/mi-support.exp +++ b/gdb/testsuite/lib/mi-support.exp @@ -32,6 +32,7 @@ set MIFLAGS "-i=mi" set thread_selected_re "=thread-selected,id=\"\[0-9\]+\"\r\n" set library_loaded_re "=library-loaded\[^\n\]+\"\r\n" +set breakpoint_re "=(breakpoint-created|breakpoint-deleted)\[^\n\]+\"\r\n" # # mi_gdb_exit -- exit the GDB, killing the target program if necessary @@ -978,6 +979,7 @@ proc mi_expect_stop { reason func args file line extra test } { global fullname_syntax global async global thread_selected_re + global breakpoint_re set after_stopped "" set after_reason "" @@ -1038,9 +1040,9 @@ proc mi_expect_stop { reason func args file line extra test } { set any "\[^\n\]*" - verbose -log "mi_expect_stop: expecting: \\*stopped,${r}${a}${bn}frame=\{addr=\"$hex\",func=\"$func\",args=$args,file=\"$any$file\",fullname=\"${fullname_syntax}$file\",line=\"$line\"\}$after_stopped,thread-id=\"$decimal\",stopped-threads=$any\r\n($thread_selected_re)?$prompt_re" + verbose -log "mi_expect_stop: expecting: \\*stopped,${r}${a}${bn}frame=\{addr=\"$hex\",func=\"$func\",args=$args,file=\"$any$file\",fullname=\"${fullname_syntax}$file\",line=\"$line\"\}$after_stopped,thread-id=\"$decimal\",stopped-threads=$any\r\n($thread_selected_re|$breakpoint_re)*$prompt_re" gdb_expect { - -re "\\*stopped,${r}${a}${bn}frame=\{addr=\"$hex\",func=\"$func\",args=$args,file=\"$any$file\",fullname=\"${fullname_syntax}$file\",line=\"($line)\"\}$after_stopped,thread-id=\"$decimal\",stopped-threads=$any\r\n($thread_selected_re)?$prompt_re" { + -re "\\*stopped,${r}${a}${bn}frame=\{addr=\"$hex\",func=\"$func\",args=$args,file=\"$any$file\",fullname=\"${fullname_syntax}$file\",line=\"($line)\"\}$after_stopped,thread-id=\"$decimal\",stopped-threads=$any\r\n($thread_selected_re|$breakpoint_re)*$prompt_re" { pass "$test" return $expect_out(2,string) } |