2008-07-12 Pedro Alves <pedro@codesourcery.com>
[deliverable/binutils-gdb.git] / gdb / ChangeLog
index df5cd3db2b5c92f22a68bf6b11f6218913c5561c..1d1f839dfac90457ae82ef7f3c322396a7b22570 100644 (file)
@@ -1,3 +1,147 @@
+2008-07-12  Pedro Alves  <pedro@codesourcery.com>
+
+       * infrun.c (struct thread_stepping_state): Delete sal member.
+       (init_thread_stepping_state): Add local sal.  Use it instead of
+       tss->sal.
+       (handle_inferior_event): New local stop_pc_sal.  Use it instead of
+       tss->sal.
+       (step_into_function): Add local stop_func_sal.  Use it instead of
+       tss->sal.
+
+2008-07-12  Vladimir Prus  <vladimir@codesourcery.com>
+
+       Implement -exec-continue/-exec-interrupt --all.
+        * infcmd.c (continue_1): New, extracted from
+        (continue_command): ...here.
+        (interrupt_target_1): New, extracted from
+        (interrupt_target_command): ...here.
+        * inferior.h (continue_1, interrupt_target_1): New.
+        * mi/mi-main.c (mi_cmd_exec_continue)
+        (mi_cmd_exec_interrupt): Handle --all.
+
+2008-07-12  Vladimir Prus  <vladimir@codesourcery.com>
+
+       Implement --thread and --frame.
+       * gdbthread.h (find_thread_id): Declare.
+        * thread.c (find_thread_id): Make non-static.
+        * mi/mi-main.c (mi_cmd_execute): Switch to the right
+        thread and frame, if necessary.
+        * mi/mi-parse.c (mi_parse): Handle --thread and --frame.
+        * mi/mi-parse.h (strcut mi_parse): New fields thread and frame.
+
+2008-07-12  Vladimir Prus  <vladimir@codesourcery.com>
+
+       * infrun.c (resume): Discard cleanups on early exit path.
+
+2008-07-12  Vladimir Prus  <vladimir@codesourcery.com>
+
+        * infrun.c (normal_stop): For MI, report which threads
+       were stopped.
+
+2008-07-12  Vladimir Prus  <vladimir@codesourcery.com>
+
+       Report thread state in -thread-info output.
+        * thread.c (print_thread_info): Add new field "state".
+
+2008-07-11  Pedro Alves  <pedro@codesourcery.com>
+
+       * infrun.c (handle_inferior_event): Also ignore a
+       TARGET_SIGNAL_TRAP on a STOP_QUIETLY_NO_SIGSTOP.
+
+2008-07-11  Tom Tromey  <tromey@redhat.com>
+
+       * completer.c (complete_line_internal): New function, from
+       complete_line.  Add 'for_help' parameter.
+       (complete_line): Use it.
+       (command_completer): Move later.  Rewrite.
+
+2008-07-11  Pedro Alves  <pedro@codesourcery.com>
+
+       * thread.c (thread_apply_command): Move making the cleanup out of
+       the loop.
+
+2008-07-11  Pedro Alves  <pedro@codesourcery.com>
+
+       Exited threads.
+
+       * thread.c (enum thread_state): New.
+       (thread_state main_thread_running): Delete, in favor of...
+       (thread_state main_thread_state): ... this.  Update throughout.
+       (clear_thread_inferior_resources): New, split from free_thread.
+       (free_thread): Call clear_thread_inferior_resources.
+       (init_thread_list): Set main thread to stopped state.
+       (add_thread_silent): Take care of PTID reuses.
+       (delete_thread): If deleting inferior_ptid or a thread with
+       refcount > 0, mark it as exited, but still keep it in the list.
+       Only notify of thread exits, if we haven't done so yet.
+       (iterate_over_threads): Make it safe to delete threads while
+       iterating over them.
+       (do_captured_list_thread_ids): Don't account for exited threads.
+       (thread_alive): Check for the THREAD_EXITED state, and don't set
+       ptid to -1 on exited threads.
+       (set_running): Update to account for extra possible states.
+       (is_thread_state): New.
+       (is_stopped, is_exited): New.
+       (is_running): Implement in terms of is_thread_state.
+       (any_running): Update.
+       (print_thread_info): Update.  Account for exited threads.  Don't
+       warn about missed frame restoring here, its done in the cleanup.
+       (switch_to_thread): Don't read from a thread that has gone.
+       (restore_current_thread): In non-stop mode, do a full context
+       switch.
+       (restore_selected_frame): Add a frame_level argument.  Rewrite.
+       (struct current_thread_cleanup): Add selected_frame_level and
+       was_stopped members.
+       (do_restore_current_thread_cleanup): Check if thread was stopped
+       and still is, and if the target has registers, stack and memory
+       before restoring the selected frame.  Don't delete the cleanup
+       argument here.
+       (restore_current_thread_cleanup_dtor): New.
+       (make_cleanup_restore_current_thread): Remove all arguments.
+       Rewrite.
+       (thread_apply_all_command): Update.  Prune threads.
+       (thread_apply_command): Update.
+       (thread_command): Account for currently selected exited thread.
+       (do_captured_thread_select): Check for a running thread.  Prune
+       threads.
+       (_initialize_thread): Make "info threads", "thread", "thread
+       apply", and "thread apply all" appliable without a selected thread.
+       * gdbthread.h (struct thread_info): Replace running_ by state_.
+       Add refcount.
+       (is_exited, is_stopped): Declare.
+       (make_cleanup_restore_current_thread): Remove all arguments.
+       * infrun.c: Include "event-top.h".
+       (fetch_inferior_event): In non-stop mode, restore selected thread
+       and frame after handling the event and running breakpoint
+       commands.  Display GDB prompt if needed.
+       (normal_stop): In non-stop mode, don't print thread switching
+       notice.
+       * cli/cli-decode.c (set_cmd_no_selected_thread_ok)
+       (get_cmd_no_selected_thread_ok): New.
+       * cli/cli-decode.h (CMD_NO_SELECTED_THREAD_OK): New.
+       (set_cmd_no_selected_thread_ok, get_cmd_no_selected_thread_ok):
+       Declare.
+       * cli/cli-cmds.c: Set "pwd", "help", "info", "show" as
+       no-selected-thread ok.
+       * top.c (execute_command): Check for non no-selected-thread-ok
+       commands.
+       * linux-nat.c (struct saved_ptids, threads_to_delete)
+       (record_dead_thread, prune_lwps): Delete.
+       (exit_lwp): Unconditionally delete thread.
+       (linux_nat_resume): Remove prune_lwps call.
+       * infcmd.c (proceed_thread_callback): Check if !is_stopped instead
+       of is_running.  Adjust to make_cleanup_restore_current_thread
+       interface change.
+       * mi/mi-main.c (mi_cmd_execute): Only allow a few commands if the
+       selected thread has exited.
+       * inf-loop.c (inferior_event_handler): Don't display the prompt
+       here.
+       * varobj.c (c_value_of_root): Update.
+       * defs.h (make_cleanup_dtor): Declare.
+       * utils.c (make_cleanup_dtor): New.
+
+       * Makefile.in (infrun.o): Depend on $(event_top_h).
+
 2008-07-11  Pedro Alves  <pedro@codesourcery.com>
 
        Add "continue -a" and "interrupt -a" options for non-stop mode.
This page took 0.025304 seconds and 4 git commands to generate.