From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 10750 invoked by alias); 25 Oct 2008 14:39:14 -0000 Mailing-List: contact archer-commits-help@sourceware.org; run by ezmlm Sender: Precedence: bulk List-Post: List-Help: List-Subscribe: Received: (qmail 10710 invoked by uid 306); 25 Oct 2008 14:39:13 -0000 Date: Sat, 25 Oct 2008 14:39:00 -0000 Message-ID: <20081025143913.10694.qmail@sourceware.org> From: tromey@sourceware.org To: archer-commits@sourceware.org Subject: [SCM] master: * ada-exp.y (write_object_renaming): Use malloc instead of X-Git-Refname: refs/heads/master X-Git-Reftype: branch X-Git-Oldrev: c2aa1872dc5c22761af3e0f1864d3008ecdfb594 X-Git-Newrev: da587f7b1f970acf8fe75fb497587242cf050d37 X-SW-Source: 2008-q4/txt/msg00047.txt.bz2 List-Id: The branch, master has been updated via da587f7b1f970acf8fe75fb497587242cf050d37 (commit) via 8e852b99282d9671b6cae2eda227736b66f9ba01 (commit) via e7bd0b6af070d62724978d04f476e4399b3f07fc (commit) via a798baf99e130e6abd223669d339e25ab9328d65 (commit) via 473ea80cf0eff03eee3b83cc17c0fa94e5f401cd (commit) via 57ccaef63375bb9e682be762ac0e78a3bc8ddcf4 (commit) via e4bab109180baf64d7b17a4693c22ecd606832e2 (commit) via 4c8f659176f6567a438f9e16b78046268a8f5eab (commit) via edb713e5e5e5957c32d898ddbc84a947cd1d0628 (commit) via b7d374bc635abdc9864ca5bc2731cb58d9d85061 (commit) via d7f2e0e3b57cd661f01d4fa004224a966c2a13a7 (commit) via 817826b312516140b09f18dd6c24f6717e7003e7 (commit) via f810c0fbcf0205da7cb5d386e86dca525c3cb86e (commit) via 87f7f592fde334c6d2dfaa0131c5001e18ac83b5 (commit) via da8ec41ebb251261a2bdd521b20e04574947726f (commit) from c2aa1872dc5c22761af3e0f1864d3008ecdfb594 (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email. - Log ----------------------------------------------------------------- commit da587f7b1f970acf8fe75fb497587242cf050d37 Author: Pedro Alves Date: Sat Oct 25 02:16:38 2008 +0000 * ada-exp.y (write_object_renaming): Use malloc instead of xmalloc. * p-exp.y (pop_current_type): Use free instead of xfree. commit 8e852b99282d9671b6cae2eda227736b66f9ba01 Author: Alan Modra Date: Sat Oct 25 00:00:05 2008 +0000 daily update commit e7bd0b6af070d62724978d04f476e4399b3f07fc Author: gdbadmin Date: Sat Oct 25 00:00:02 2008 +0000 *** empty log message *** commit a798baf99e130e6abd223669d339e25ab9328d65 Author: Pedro Alves Date: Fri Oct 24 22:01:24 2008 +0000 * fork-child.c (startup_inferior): Only set threads not-executing after getting all the pending execs. On TARGET_WAITKIND_IGNORE, keep waiting, don't resume. On all other cases but TARGET_WAITKIND_SIGNALLED and TARGET_WAITKIND_EXITED, switch to the event ptid. commit 473ea80cf0eff03eee3b83cc17c0fa94e5f401cd Author: Daniel Jacobowitz Date: Fri Oct 24 21:58:34 2008 +0000 * Makefile.tpl (HOST_EXPORTS): Correct CPPFLAGS typo. * Makefile.in: Regenerated. commit 57ccaef63375bb9e682be762ac0e78a3bc8ddcf4 Author: Sandra Loosemore Date: Fri Oct 24 21:04:22 2008 +0000 2008-10-24 Sandra Loosemore gdb/doc * gdb.texinfo (Remote Protocol): Add new nodes to menu. (Overview): Mention notifications and non-stop mode behavior. (Packets): Update documentation of ?, vAttach, vCont, and vRun with non-stop mode behavior. Add vStopped description. (Stop Reply Packets): Update list of packets that return stop replies. Mention non-stop behavior. (General Query Packets): Document QNonStop packet and associated qSupported query response. (Interrupts): Clarify multi-threaded behavior. Mention non-stop behavior. (Notification Packets): New section. (Remote Non-Stop): New section. (File-I/O Overview): Mention non-stop behavior. commit e4bab109180baf64d7b17a4693c22ecd606832e2 Author: Pedro Alves Date: Fri Oct 24 20:38:25 2008 +0000 Remote non-stop mode support. * remote.c (pending_stop_reply): New. (struct remote_state) : New fields. (remote_async_inferior_event_token) (remote_async_get_pending_events_token): New. (notice_new_inferiors): New, abstracted out from record_currthread. (record_currthread): Call it. (remote_threads_info): Default threads to running in non-stop mode. In non-stop mode, only qfThreadInfo is supported. (remote_close): Discard all pending stop_replies. Close the event sources. (set_stop_requested_callback): New. (remote_start_remote): Implement non-stop mode startup. In all-stop, don't clear the thread list here. (remote_non_stop_feature): New. (remote_protocol_features): Add a "QNonStop" feature. (remote_open_1): Clear cached_wait_status and non_stop_aware. Clear the thread list here. (remote_detach_1): Discard pending stop replies of the process we detached from. (extended_remote_attach_1): Implement non-stop mode. (remote_vcont_probe): Recognize `vCont;t'. (remote_vcont_resume): Implement non-stop mode. (remote_resume): Don't set waiting_for_stop_reply in non-stop mode. (remote_stop_ns): New. (remote_stop): Rename to ... (remote_stop_as): ... this. If we have a cached wait status, don't bother interrupting the remote. (remote_stop): Reimplement as wrapper around remote_stop_as and remote_stop_ns. (interrupt_query): Don't query in async mode. (struct cached_reg, cahed_reg_t): New. (struct stop_reply): New. (stop_reply_queue): New. (stop_reply_xmalloc, stop_reply_xfree) (discard_pending_stop_replies, do_stop_reply_xfree) (queued_stop_reply, push_stop_reply, peek_stop_reply) (remote_parse_stop_reply, remote_get_pending_stop_replies) (process_stop_reply): New. (remote_wait_ns): New. (remote_wait_as): Use remote_parse_stop_reply. Invalidate the notion of current general thread is a process exit was reported. (remote_wait): Call remote_wait_ns in non-stop mode. (handle_notification): New. (putpkt_binary): Handle notifications. Don't care for waiting_for_stop_reply in non-stop mode. (getpkt_sane): Rename to ... (getpkt_or_notif_sane_1): ... this. Add `expecting_notif' argument. Handle it. Handle notifications. (getpkt_sane): Reimplement as wrapper around getpkt_or_notif_sane_1. (getpkt_or_notif_sane): New. (select_new_thread_callback): Check for exited state instead of comparing the ptid against minus_one_ptid. (extended_remote_create_inferior_1): Query the remote about the current thread. (remote_supports_non_stop): New. (init_remote_ops): Register it. (remote_async_inferior_event_handler): New. (remote_async_get_pending_events_handler): New. * infcmd.c (proceed_thread_callback): Comment. (proceed_after_attach_callback, proceed_after_attach): New. (attach_command_post_wait): In background attach, resume all threads, but only if they are unsignalled, and not explicitly stopped. In foreground attach, in non-stop mode, make sure to stop all threads of the just attached to process. (attach_command): In non-stop mode: If doing a background attach, stop at least one thread. If a foreground attach, stop all threads. commit 4c8f659176f6567a438f9e16b78046268a8f5eab Author: Pedro Alves Date: Fri Oct 24 19:33:39 2008 +0000 * event-loop.h: Mention async_event_handlers. (async_event_handler): Forward declare. (async_event_handler_func): New typedef. (create_async_event_handler, delete_async_event_handler) (mark_async_event_handler): Declare. * event-loop.c (event_data): New. (event_handler_func): Take an event_data instead of an integer. (struct gdb_event): Replace the integer file descriptor by a generic event_data. (async_event_handler): New. (async_handler_ready): Delete. (async_event_handler_list): New. (create_event): New. (create_file_event): Use it. (process_event): Adjust. (gdb_do_one_event): Poll from the event sources in round-robin fashion across calls. Be sure to consult all sources before blocking. (handle_file_event): Take an event_data instead of an integer. Adjust. (gdb_wait_for_event): Add `block' argument. Handle it. (mark_async_signal_handler): Remove unneeded cast. (invoke_async_signal_handler): Rename to ... (invoke_async_signal_handlres): ... this. Return true if any was handled. (check_async_ready): Delete (create_async_event_handler): New. (mark_async_event_handler): New. (struct async_event_handler_data): New. (invoke_async_event_handler): New. (check_async_event_handlers): New. (delete_async_event_handler): New. (handle_timer_event): Adjust. commit edb713e5e5e5957c32d898ddbc84a947cd1d0628 Author: Pedro Alves Date: Fri Oct 24 18:54:02 2008 +0000 * gdb.python/python-value.exp (test_value_in_inferior): Don't use gdb_start_cmd. Use runto_main before any test that requires execution. commit b7d374bc635abdc9864ca5bc2731cb58d9d85061 Author: Doug Evans Date: Fri Oct 24 18:21:00 2008 +0000 * dwarf2read.c (typename_concat): Don't segv if prefix or suffix is NULL. Simplify obs == NULL case. commit d7f2e0e3b57cd661f01d4fa004224a966c2a13a7 Author: Hui Zhu Date: Fri Oct 24 02:31:40 2008 +0000 2008-10-24 Hui Zhu Pedro Alves * infrun.c (can_use_displaced_stepping): Change type to const char pointer. (can_use_displaced_stepping_auto): New string. (can_use_displaced_stepping_on): New string. (can_use_displaced_stepping_off): New string. (can_use_displaced_stepping_enum): New array. (show_can_use_displaced_stepping): In auto mode, also show the current effect of the option. (use_displaced_stepping): Return non-zero if displaced stepping is auto, and can be used with GDBARCH, and in non-stop mode. Return non-zero if displaced stepping is on, and can be used with GDBARCH. Return zero otherwise. (_initialize_infrun): Make the "set displaced-stepping" command an enum command. Change its class to class_run. Place it in the top level set list. Extend help to describe the auto mode. 2008-10-24 Hui Zhu Pedro Alves * gdb.texinfo (displaced-stepping): Describe the auto mode setting, and say it's the default. This is now a mainstream setting instead of a maintenance setting. commit 817826b312516140b09f18dd6c24f6717e7003e7 Author: Alan Modra Date: Fri Oct 24 00:00:04 2008 +0000 daily update commit f810c0fbcf0205da7cb5d386e86dca525c3cb86e Author: gdbadmin Date: Fri Oct 24 00:00:03 2008 +0000 *** empty log message *** commit 87f7f592fde334c6d2dfaa0131c5001e18ac83b5 Author: Pedro Alves Date: Thu Oct 23 23:11:20 2008 +0000 gdb/ 2008-10-23 Pedro Alves * defs.h: Mention ptid_is_pid. * inferior.h (ptid_is_pid): Declare. * gdbthread.h (struct thread_info) : New field. (set_stop_requested): Declare. * infcmd.c (interrupt_target_1): Call set_stop_requested. * infrun.c (clear_proceed_status): Clear stop_requested. (infrun_thread_stop_requested_callback, infrun_thread_stop_requested): New. (handle_inferior_event): If a TARGET_SIGNAL_TRAP is reported on a thread that had an explicit stop request, pretend we got a TARGET_SIGNAL_0. Always stop if the thread had an explicit stop request. (print_stop_reason): In the SIGNAL_RECEIVED case, if we're not outputting to MI, and we got a TARGET_SIGNAL_0, print "# Stopped", instead of mentioning signal 0. (ptid_is_pid): New. * thread.c (set_stop_requested): New. * linux-nat.c (queued_waitpid): Rename to ... (queued_waitpid_1): ... this. Add `peek' argument. Handle it. (queued_waitpid): New, as wrapper to queued_waitpid_1. (push_waitpid): Push the SIGTRAP to the local event queue, to the kernel's. (send_sigint_callback): Delete. (linux_nat_stop_lwp): New. (linux_nat_stop): Use it. gdb/doc/ 2008-10-23 Pedro Alves * observer.texi (thread_stop_requested): New. gdb/testsuite/ 2008-10-23 Pedro Alves * lib/mi-support.exp (mi_expect_interrupt): Expect signal 0 instead of SIGINT. commit da8ec41ebb251261a2bdd521b20e04574947726f Author: Paul Pluzhnikov Date: Thu Oct 23 22:48:30 2008 +0000 2008-10-23 Paul Pluzhnikov * python/python-value (valpy_getitem): Fix heap corruption. ----------------------------------------------------------------------- Summary of changes: ChangeLog | 5 + Makefile.in | 2 +- Makefile.tpl | 2 +- bfd/version.h | 2 +- gdb/ChangeLog | 183 ++++ gdb/ada-exp.y | 2 +- gdb/defs.h | 1 + gdb/doc/ChangeLog | 27 + gdb/doc/gdb.texinfo | 303 ++++++- gdb/doc/observer.texi | 8 + gdb/dwarf2read.c | 18 +- gdb/event-loop.c | 382 +++++++-- gdb/event-loop.h | 54 +- gdb/fork-child.c | 27 +- gdb/gdbthread.h | 10 + gdb/infcmd.c | 110 +++- gdb/inferior.h | 3 + gdb/infrun.c | 246 +++++- gdb/linux-nat.c | 128 +++- gdb/p-exp.y | 2 +- gdb/python/python-value.c | 3 +- gdb/remote.c | 1310 ++++++++++++++++++++++++----- gdb/testsuite/ChangeLog | 11 + gdb/testsuite/gdb.python/python-value.exp | 13 +- gdb/testsuite/lib/mi-support.exp | 2 +- gdb/thread.c | 25 + gdb/version.in | 2 +- 27 files changed, 2446 insertions(+), 435 deletions(-) First 500 lines of diff: diff --git a/ChangeLog b/ChangeLog index 85e2a74..141b7aa 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2008-10-24 Daniel Jacobowitz + + * Makefile.tpl (HOST_EXPORTS): Correct CPPFLAGS typo. + * Makefile.in: Regenerated. + 2008-10-22 Daniel Jacobowitz PR gdb/921 diff --git a/Makefile.in b/Makefile.in index aaf210b..e94018b 100644 --- a/Makefile.in +++ b/Makefile.in @@ -174,7 +174,7 @@ HOST_EXPORTS = \ ADA_CFLAGS="$(ADA_CFLAGS)"; export ADA_CFLAGS; \ CFLAGS="$(CFLAGS)"; export CFLAGS; \ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \ - CPPFLAGS="$(CFLAGS)"; export CPPFLAGS; \ + CPPFLAGS="$(CPPFLAGS)"; export CPPFLAGS; \ CXX="$(CXX)"; export CXX; \ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \ AR="$(AR)"; export AR; \ diff --git a/Makefile.tpl b/Makefile.tpl index 4847df6..51f5979 100644 --- a/Makefile.tpl +++ b/Makefile.tpl @@ -177,7 +177,7 @@ HOST_EXPORTS = \ ADA_CFLAGS="$(ADA_CFLAGS)"; export ADA_CFLAGS; \ CFLAGS="$(CFLAGS)"; export CFLAGS; \ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \ - CPPFLAGS="$(CFLAGS)"; export CPPFLAGS; \ + CPPFLAGS="$(CPPFLAGS)"; export CPPFLAGS; \ CXX="$(CXX)"; export CXX; \ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \ AR="$(AR)"; export AR; \ diff --git a/bfd/version.h b/bfd/version.h index f1e5e0f..8935185 100644 --- a/bfd/version.h +++ b/bfd/version.h @@ -1,4 +1,4 @@ -#define BFD_VERSION_DATE 20081023 +#define BFD_VERSION_DATE 20081025 #define BFD_VERSION @bfd_version@ #define BFD_VERSION_STRING @bfd_version_package@ @bfd_version_string@ #define REPORT_BUGS_TO @report_bugs_to@ diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 8362188..c30272b 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,186 @@ +2008-10-25 Pedro Alves + + * ada-exp.y (write_object_renaming): Use malloc instead of + xmalloc. + * p-exp.y (pop_current_type): Use free instead of xfree. + +2008-10-24 Pedro Alves + + * fork-child.c (startup_inferior): Only set threads not-executing + after getting all the pending execs. On TARGET_WAITKIND_IGNORE, + keep waiting, don't resume. On all other cases but + TARGET_WAITKIND_SIGNALLED and TARGET_WAITKIND_EXITED, switch to + the event ptid. + +2008-10-24 Pedro Alves + + Remote non-stop mode support. + + * remote.c (pending_stop_reply): New. + (struct remote_state) : New + fields. + (remote_async_inferior_event_token) + (remote_async_get_pending_events_token): New. + (notice_new_inferiors): New, abstracted out from record_currthread. + (record_currthread): Call it. + (remote_threads_info): Default threads to running in non-stop + mode. In non-stop mode, only qfThreadInfo is supported. + (remote_close): Discard all pending stop_replies. Close the event + sources. + (set_stop_requested_callback): New. + (remote_start_remote): Implement non-stop mode startup. In + all-stop, don't clear the thread list here. + (remote_non_stop_feature): New. + (remote_protocol_features): Add a "QNonStop" feature. + (remote_open_1): Clear cached_wait_status and non_stop_aware. + Clear the thread list here. + (remote_detach_1): Discard pending stop replies of the process we + detached from. + (extended_remote_attach_1): Implement non-stop mode. + (remote_vcont_probe): Recognize `vCont;t'. + (remote_vcont_resume): Implement non-stop mode. + (remote_resume): Don't set waiting_for_stop_reply in non-stop + mode. + (remote_stop_ns): New. + (remote_stop): Rename to ... + (remote_stop_as): ... this. If we have a cached wait status, + don't bother interrupting the remote. + (remote_stop): Reimplement as wrapper around remote_stop_as and + remote_stop_ns. + (interrupt_query): Don't query in async mode. + (struct cached_reg, cahed_reg_t): New. + (struct stop_reply): New. + (stop_reply_queue): New. + (stop_reply_xmalloc, stop_reply_xfree) + (discard_pending_stop_replies, do_stop_reply_xfree) + (queued_stop_reply, push_stop_reply, peek_stop_reply) + (remote_parse_stop_reply, remote_get_pending_stop_replies) + (process_stop_reply): New. + (remote_wait_ns): New. + (remote_wait_as): Use remote_parse_stop_reply. Invalidate the + notion of current general thread is a process exit was reported. + (remote_wait): Call remote_wait_ns in non-stop mode. + (handle_notification): New. + (putpkt_binary): Handle notifications. Don't care for + waiting_for_stop_reply in non-stop mode. + (getpkt_sane): Rename to ... + (getpkt_or_notif_sane_1): ... this. Add `expecting_notif' + argument. Handle it. Handle notifications. + (getpkt_sane): Reimplement as wrapper around getpkt_or_notif_sane_1. + (getpkt_or_notif_sane): New. + (select_new_thread_callback): Check for exited state instead of + comparing the ptid against minus_one_ptid. + (extended_remote_create_inferior_1): Query the remote about the + current thread. + (remote_supports_non_stop): New. + (init_remote_ops): Register it. + (remote_async_inferior_event_handler): New. + (remote_async_get_pending_events_handler): New. + + * infcmd.c (proceed_thread_callback): Comment. + (proceed_after_attach_callback, proceed_after_attach): New. + (attach_command_post_wait): In background attach, resume all + threads, but only if they are unsignalled, and not explicitly + stopped. In foreground attach, in non-stop mode, make sure to + stop all threads of the just attached to process. + (attach_command): In non-stop mode: If doing a background attach, + stop at least one thread. If a foreground attach, stop all + threads. + +2008-10-24 Pedro Alves + + * event-loop.h: Mention async_event_handlers. + (async_event_handler): Forward declare. + (async_event_handler_func): New typedef. + (create_async_event_handler, delete_async_event_handler) + (mark_async_event_handler): Declare. + * event-loop.c (event_data): New. + (event_handler_func): Take an event_data instead of an integer. + (struct gdb_event): Replace the integer file descriptor by a + generic event_data. + (async_event_handler): New. + (async_handler_ready): Delete. + (async_event_handler_list): New. + (create_event): New. + (create_file_event): Use it. + (process_event): Adjust. + (gdb_do_one_event): Poll from the event sources in round-robin + fashion across calls. Be sure to consult all sources before + blocking. + (handle_file_event): Take an event_data instead of an integer. + Adjust. + (gdb_wait_for_event): Add `block' argument. Handle it. + (mark_async_signal_handler): Remove unneeded cast. + (invoke_async_signal_handler): Rename to ... + (invoke_async_signal_handlres): ... this. Return true if any was + handled. + (check_async_ready): Delete + (create_async_event_handler): New. + (mark_async_event_handler): New. + (struct async_event_handler_data): New. + (invoke_async_event_handler): New. + (check_async_event_handlers): New. + (delete_async_event_handler): New. + (handle_timer_event): Adjust. + +2008-10-24 Doug Evans + + * dwarf2read.c (typename_concat): Don't segv if prefix or suffix + is NULL. Simplify obs == NULL case. + +2008-10-24 Hui Zhu + Pedro Alves + + * infrun.c (can_use_displaced_stepping): Change type to + const char pointer. + (can_use_displaced_stepping_auto): New string. + (can_use_displaced_stepping_on): New string. + (can_use_displaced_stepping_off): New string. + (can_use_displaced_stepping_enum): New array. + (show_can_use_displaced_stepping): In auto mode, also show + the current effect of the option. + (use_displaced_stepping): Return non-zero if displaced + stepping is auto, and can be used with GDBARCH, and in + non-stop mode. Return non-zero if displaced stepping is on, + and can be used with GDBARCH. Return zero otherwise. + (_initialize_infrun): Make the "set displaced-stepping" + command an enum command. Change its class to class_run. + Place it in the top level set list. Extend help to describe + the auto mode. + +2008-10-23 Pedro Alves + + * defs.h: Mention ptid_is_pid. + * inferior.h (ptid_is_pid): Declare. + * gdbthread.h (struct thread_info) : New field. + (set_stop_requested): Declare. + * infcmd.c (interrupt_target_1): Call set_stop_requested. + * infrun.c (clear_proceed_status): Clear stop_requested. + (infrun_thread_stop_requested_callback, + infrun_thread_stop_requested): New. + (handle_inferior_event): If a TARGET_SIGNAL_TRAP is reported on a + thread that had an explicit stop request, pretend we got a + TARGET_SIGNAL_0. Always stop if the thread had an explicit stop + request. + (print_stop_reason): In the SIGNAL_RECEIVED case, if we're not + outputting to MI, and we got a TARGET_SIGNAL_0, print "# Stopped", + instead of mentioning signal 0. + (ptid_is_pid): New. + * thread.c (set_stop_requested): New. + + * linux-nat.c (queued_waitpid): Rename to ... + (queued_waitpid_1): ... this. Add `peek' argument. Handle it. + (queued_waitpid): New, as wrapper to queued_waitpid_1. + (push_waitpid): Push the SIGTRAP to the local event queue, to the + kernel's. + (send_sigint_callback): Delete. + (linux_nat_stop_lwp): New. + (linux_nat_stop): Use it. + +2008-10-23 Paul Pluzhnikov + + * python/python-value (valpy_getitem): Fix heap corruption. + 2008-10-23 Aleksandar Ristovski * nto-procfs.c (do_attach): Form proper ptid including pid and tid. diff --git a/gdb/ada-exp.y b/gdb/ada-exp.y index e440663..4b8bb93 100644 --- a/gdb/ada-exp.y +++ b/gdb/ada-exp.y @@ -987,7 +987,7 @@ write_object_renaming (struct block *orig_left_context, if (end == NULL) end = renaming_expr + strlen (renaming_expr); field_name.length = end - renaming_expr; - field_name.ptr = xmalloc (end - renaming_expr + 1); + field_name.ptr = malloc (end - renaming_expr + 1); strncpy (field_name.ptr, renaming_expr, end - renaming_expr); field_name.ptr[end - renaming_expr] = '\000'; renaming_expr = end; diff --git a/gdb/defs.h b/gdb/defs.h index 5b718a3..42dd821 100644 --- a/gdb/defs.h +++ b/gdb/defs.h @@ -752,6 +752,7 @@ enum val_prettyprint ptid_get_lwp - Fetch the lwp component of a ptid. ptid_get_tid - Fetch the tid component of a ptid. ptid_equal - Test to see if two ptids are equal. + ptid_is_pid - Test to see if this ptid represents a process id. Please do NOT access the struct ptid members directly (except, of course, in the implementation of the above ptid manipulation diff --git a/gdb/doc/ChangeLog b/gdb/doc/ChangeLog index 5a79cea..6b05575 100644 --- a/gdb/doc/ChangeLog +++ b/gdb/doc/ChangeLog @@ -1,3 +1,30 @@ +2008-10-24 Sandra Loosemore + + * gdb.texinfo (Remote Protocol): Add new nodes to menu. + (Overview): Mention notifications and non-stop mode behavior. + (Packets): Update documentation of ?, vAttach, vCont, and vRun + with non-stop mode behavior. Add vStopped description. + (Stop Reply Packets): Update list of packets that return + stop replies. Mention non-stop behavior. + (General Query Packets): Document QNonStop packet and associated + qSupported query response. + (Interrupts): Clarify multi-threaded behavior. Mention non-stop + behavior. + (Notification Packets): New section. + (Remote Non-Stop): New section. + (File-I/O Overview): Mention non-stop behavior. + +2008-10-24 Hui Zhu + Pedro Alves + + * gdb.texinfo (displaced-stepping): Describe the auto mode + setting, and say it's the default. This is now a mainstream + setting instead of a maintenance setting. + +2008-10-23 Pedro Alves + + * observer.texi (thread_stop_requested): New. + 2008-10-22 Joel Brobecker * gdb.texinfo (Ada Tasks, Ada Tasks and Core Files): New nodes. diff --git a/gdb/doc/gdb.texinfo b/gdb/doc/gdb.texinfo index c003cd4..261d1c7 100644 --- a/gdb/doc/gdb.texinfo +++ b/gdb/doc/gdb.texinfo @@ -24296,18 +24296,33 @@ Shared library events. @end table -@kindex maint set can-use-displaced-stepping -@kindex maint show can-use-displaced-stepping +@kindex set displaced-stepping +@kindex show displaced-stepping @cindex displaced stepping support @cindex out-of-line single-stepping -@item maint set can-use-displaced-stepping -@itemx maint show can-use-displaced-stepping +@item set displaced-stepping +@itemx show displaced-stepping Control whether or not @value{GDBN} will do @dfn{displaced stepping} -if the target supports it. The default is on. Displaced stepping is -a way to single-step over breakpoints without removing them from the -inferior, by executing an out-of-line copy of the instruction that was -originally at the breakpoint location. It is also known as -out-of-line single-stepping. +if the target supports it. Displaced stepping is a way to single-step +over breakpoints without removing them from the inferior, by executing +an out-of-line copy of the instruction that was originally at the +breakpoint location. It is also known as out-of-line single-stepping. + +@table @code +@item set displaced-stepping on +If the target architecture supports it, @value{GDBN} will use +displaced stepping to step over breakpoints. + +@item set displaced-stepping off +@value{GDBN} will not use displaced stepping to step over breakpoints, +even if such is supported by the target architecture. + +@cindex non-stop mode, and @samp{set displaced-stepping} +@item set displaced-stepping auto +This is the default mode. @value{GDBN} will use displaced stepping +only if non-stop mode is active (@pxref{Non-Stop Mode}) and the target +architecture supports displaced stepping. +@end table @kindex maint check-symtabs @item maint check-symtabs @@ -24623,6 +24638,8 @@ Show the current setting of the target wait timeout. * Tracepoint Packets:: * Host I/O Packets:: * Interrupts:: +* Notification Packets:: +* Remote Non-Stop:: * Packet Acknowledgment:: * Examples:: * File-I/O Remote Protocol Extension:: @@ -24644,8 +24661,9 @@ transmitted and received data, respectively. @cindex protocol, @value{GDBN} remote serial @cindex serial protocol, @value{GDBN} remote @cindex remote serial protocol -All @value{GDBN} commands and responses (other than acknowledgments) are -sent as a @var{packet}. A @var{packet} is introduced with the character +All @value{GDBN} commands and responses (other than acknowledgments +and notifications, see @ref{Notification Packets}) are sent as a +@var{packet}. A @var{packet} is introduced with the character @samp{$}, the actual @var{packet-data}, and the terminating character @samp{#} followed by a two-digit @var{checksum}: @@ -24691,7 +24709,10 @@ once a connection is established. The host (@value{GDBN}) sends @var{command}s, and the target (the debugging stub incorporated in your program) sends a @var{response}. In the case of step and continue @var{command}s, the response is only sent -when the operation has completed (the target has again stopped). +when the operation has completed, and the target has again stopped all +threads in all attached processes. This is the default all-stop mode +behavior, but the remote protocol also supports @value{GDBN}'s non-stop +execution mode; see @ref{Remote Non-Stop}, for details. @var{packet-data} consists of a sequence of characters with the exception of @samp{#} and @samp{$} (see @samp{X} packet for additional @@ -24827,7 +24848,8 @@ The remote target both supports and has enabled extended mode. @item ? @cindex @samp{?} packet Indicate the reason the target halted. The reply is the same as for -step and continue. +step and continue. This packet has a special interpretation when the +target is in non-stop mode; see @ref{Remote Non-Stop}. Reply: @xref{Stop Reply Packets}, for the reply specifications. @@ -25147,9 +25169,20 @@ up to the first @samp{;} or @samp{?} (or the end of the packet). @item vAttach;@var{pid} @cindex @samp{vAttach} packet -Attach to a new process with the specified process ID. @var{pid} is a -hexadecimal integer identifying the process. The attached process is -stopped. +Attach to a new process with the specified process ID @var{pid}. +The process ID is a +hexadecimal integer identifying the process. In all-stop mode, all +threads in the attached process are stopped; in non-stop mode, it may be +attached without being stopped if that is supported by the target. + +@c In non-stop mode, on a successful vAttach, the stub should set the +@c current thread to a thread of the newly-attached process. After +@c attaching, GDB queries for the attached process's thread ID with qC. +@c Also note that, from a user perspective, whether or not the +@c target is stopped on attach in non-stop mode depends on whether you +@c use the foreground or background version of the attach command, not +@c on what vAttach does; GDB does the right thing with respect to either +@c stopping or restarting threads. This packet is only available in extended mode (@pxref{extended mode}). @@ -25158,7 +25191,9 @@ Reply: @item E @var{nn} for an error @item @r{Any stop packet} -for success (@pxref{Stop Reply Packets}) +for success in all-stop mode (@pxref{Stop Reply Packets}) +@item OK +for success in non-stop mode (@pxref{Remote Non-Stop}) @end table @item vCont@r{[};@var{action}@r{[}:@var{thread-id}@r{]]}@dots{} @@ -25166,7 +25201,9 @@ for success (@pxref{Stop Reply Packets}) Resume the inferior, specifying different actions for each thread. If an action is specified with no @var{thread-id}, then it is applied to any threads that don't have a specific action specified; if no default action is -specified then other threads should remain stopped. Specifying multiple +specified then other threads should remain stopped in all-stop mode and +in their current state in non-stop mode. +Specifying multiple default actions is an error; specifying no actions is also an error. Thread IDs are specified using the syntax described in @ref{thread-id syntax}. @@ -25176,16 +25213,29 @@ Currently supported actions are: @item c Continue. @item C @var{sig} -Continue with signal @var{sig}. @var{sig} should be two hex digits. +Continue with signal @var{sig}. The signal @var{sig} should be two hex digits. @item s Step. @item S @var{sig} -Step with signal @var{sig}. @var{sig} should be two hex digits. +Step with signal @var{sig}. The signal @var{sig} should be two hex digits. +@item t +Stop. +@item T @var{sig} +Stop with signal @var{sig}. The signal @var{sig} should be two hex digits. @end table -The optional @var{addr} argument normally associated with these packets is +The optional argument @var{addr} normally associated with the +@samp{c}, @samp{C}, @samp{s}, and @samp{S} packets is not supported in @samp{vCont}. +The @samp{t} and @samp{T} actions are only relevant in non-stop mode +(@pxref{Remote Non-Stop}) and may be ignored by the stub otherwise. +A stop reply should be generated for any affected thread not already stopped. +When a thread is stopped by means of a @samp{t} action, +the corresponding stop reply should indicate that the thread has stopped with +signal @samp{0}, regardless of whether the target uses some other signal +as an implementation detail. + Reply: @xref{Stop Reply Packets}, for the reply specifications. @@ -25288,6 +25338,8 @@ command line. The file and arguments are hex-encoded strings. If (e.g.@: the last program run). The program is created in the stopped state. +@c FIXME: What about non-stop mode? + This packet is only available in extended mode (@pxref{extended mode}). Reply: @@ -25298,6 +25350,21 @@ for an error for success (@pxref{Stop Reply Packets}) @end table +@item vStopped +@anchor{vStopped packet} +@cindex @samp{vStopped} packet + +In non-stop mode (@pxref{Remote Non-Stop}), acknowledge a previous stop +reply and prompt for the stub to report another one. + +Reply: +@table @samp +@item @r{Any stop packet} +if there is another unreported stop event (@pxref{Stop Reply Packets}) +@item OK +if there are no unreported stop events +@end table + @item X @var{addr},@var{length}:@var{XX@dots{}} @anchor{X packet} @cindex @samp{X} packet hooks/post-receive -- Repository for Project Archer.