aboutsummaryrefslogtreecommitdiff
path: root/gdb/gdbthread.h
diff options
context:
space:
mode:
authorVladimir Prus <vladimir@codesourcery.com>2008-06-10 10:23:54 +0000
committerVladimir Prus <vladimir@codesourcery.com>2008-06-10 10:23:54 +0000
commite1ac3328737bc34a23dbfff92b416a9d9306329a (patch)
treea6ffb502159f70dbab8c069def57709877ec7b9d /gdb/gdbthread.h
parentf7f9a841a31878b377a60bfc7c793e6c8400fafe (diff)
downloadgdb-e1ac3328737bc34a23dbfff92b416a9d9306329a.zip
gdb-e1ac3328737bc34a23dbfff92b416a9d9306329a.tar.gz
gdb-e1ac3328737bc34a23dbfff92b416a9d9306329a.tar.bz2
Implement *running.
* Makefile.in: Update dependencies. * gdbthread.h (struct thread_info): New field running_. (set_running, is_running): New. * thread.c (set_running, is_running): New. * inferior.h (suppress_normal_stop_observer): Rename to... (suppress_run_stop_observers): ..this. * infcmd.c (suppress_normal_stop_observer): Rename to... (suppress_run_stop_observers): ..this. (finish_command_continuation, finish_command): Adjust. * infcall.c (call_function_by_hand): Adjust. * infrun.c (normal_stop): Call set_running. * target.c (target_resume): New. Call set_running. * target.h (target_resume): Convert from macro to a function. * mi/mi-interp.c (mi_on_resume): New. (mi_interpreter_init): Register mi_on_resume.
Diffstat (limited to 'gdb/gdbthread.h')
-rw-r--r--gdb/gdbthread.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/gdb/gdbthread.h b/gdb/gdbthread.h
index 5f9e985..4440417 100644
--- a/gdb/gdbthread.h
+++ b/gdb/gdbthread.h
@@ -63,6 +63,10 @@ struct thread_info
when we finally do stop stepping. */
bpstat stepping_through_solib_catchpoints;
+ /* This field is internal for thread.c. Never access it directly,
+ use is_running instead. */
+ int running_;
+
/* Private data used by the target vector implementation. */
struct private_thread_info *private;
};
@@ -146,6 +150,13 @@ extern void load_infrun_state (ptid_t ptid,
/* Switch from one thread to another. */
extern void switch_to_thread (ptid_t ptid);
+/* Marks thread PTID is running, or stopped.
+ If PIDGET (PTID) is -1, marks all threads. */
+extern void set_running (ptid_t ptid, int running);
+
+/* Reports if thread PTID is know to be running right now. */
+extern int is_running (ptid_t ptid);
+
/* Commands with a prefix of `thread'. */
extern struct cmd_list_element *thread_cmd_list;