projects
/
deliverable
/
binutils-gdb.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Switch current_thread to lwp's thread in install_software_single_step_breakpoints
[deliverable/binutils-gdb.git]
/
gdb
/
gdbserver
/
gdbthread.h
diff --git
a/gdb/gdbserver/gdbthread.h
b/gdb/gdbserver/gdbthread.h
index 5d4955b5d154687050c542920715e2d82fb0b054..d2326fb0590b3602148ced9a8396cb8952d11ba1 100644
(file)
--- a/
gdb/gdbserver/gdbthread.h
+++ b/
gdb/gdbserver/gdbthread.h
@@
-1,5
+1,5
@@
/* Multi-thread control defs for remote server for GDB.
/* Multi-thread control defs for remote server for GDB.
- Copyright (C) 1993-201
3
Free Software Foundation, Inc.
+ Copyright (C) 1993-201
6
Free Software Foundation, Inc.
This file is part of GDB.
This file is part of GDB.
@@
-19,15
+19,19
@@
#ifndef GDB_THREAD_H
#define GDB_THREAD_H
#ifndef GDB_THREAD_H
#define GDB_THREAD_H
-#include "
server
.h"
+#include "
inferiors
.h"
struct btrace_target_info;
struct btrace_target_info;
+struct regcache;
struct thread_info
{
struct thread_info
{
+ /* This must appear first. See inferiors.h.
+ The list iterator functions assume it. */
struct inferior_list_entry entry;
struct inferior_list_entry entry;
+
void *target_data;
void *target_data;
-
void
*regcache_data;
+
struct regcache
*regcache_data;
/* The last resume GDB requested on this thread. */
enum resume_kind last_resume_kind;
/* The last resume GDB requested on this thread. */
enum resume_kind last_resume_kind;
@@
-35,6
+39,9
@@
struct thread_info
/* The last wait status reported for this thread. */
struct target_waitstatus last_status;
/* The last wait status reported for this thread. */
struct target_waitstatus last_status;
+ /* True if LAST_STATUS hasn't been reported to GDB yet. */
+ int status_pending_p;
+
/* Given `while-stepping', a thread may be collecting data for more
than one tracepoint simultaneously. E.g.:
/* Given `while-stepping', a thread may be collecting data for more
than one tracepoint simultaneously. E.g.:
@@
-67,11
+74,20
@@
struct thread_info
extern struct inferior_list all_threads;
void remove_thread (struct thread_info *thread);
extern struct inferior_list all_threads;
void remove_thread (struct thread_info *thread);
-void add_thread (ptid_t ptid, void *target_data);
+struct thread_info *add_thread (ptid_t ptid, void *target_data);
+
+struct thread_info *get_first_thread (void);
struct thread_info *find_thread_ptid (ptid_t ptid);
struct thread_info *find_thread_ptid (ptid_t ptid);
-struct thread_info *gdb_id_to_thread (unsigned int);
+
+/* Find any thread of the PID process. Returns NULL if none is
+ found. */
+struct thread_info *find_any_thread_of_pid (int pid);
/* Get current thread ID (Linux task ID). */
/* Get current thread ID (Linux task ID). */
-#define current_ptid ((struct inferior_list_entry *) current_inferior)->id
+#define current_ptid (current_thread->entry.id)
+
+/* Create a cleanup to restore current_thread. */
+struct cleanup *make_cleanup_restore_current_thread (void);
+
#endif /* GDB_THREAD_H */
#endif /* GDB_THREAD_H */
This page took
0.025696 seconds
and
4
git commands to generate.