summaryrefslogtreecommitdiff
path: root/gdb/sol-thread.c
diff options
context:
space:
mode:
authorKevin Buettner <kevinb@redhat.com>2001-05-15 00:03:38 +0000
committerKevin Buettner <kevinb@redhat.com>2001-05-15 00:03:38 +0000
commit11bc5832a9da5c23b3df59251c230c5bcce21f2f (patch)
tree50f0f065461a8b7af6dd698436b44c709296173d /gdb/sol-thread.c
parent2e9e5ed6071269ff915c1caa9a9735849fd7c15b (diff)
downloadgdb-11bc5832a9da5c23b3df59251c230c5bcce21f2f.tar.gz
Redefine ptid_t to be a struct rather than an int.
Diffstat (limited to 'gdb/sol-thread.c')
-rw-r--r--gdb/sol-thread.c17
1 files changed, 9 insertions, 8 deletions
diff --git a/gdb/sol-thread.c b/gdb/sol-thread.c
index cf8f33c9843..f92c49e4b3f 100644
--- a/gdb/sol-thread.c
+++ b/gdb/sol-thread.c
@@ -111,14 +111,15 @@ static void init_sol_core_ops (void);
/* Default definitions: These must be defined in tm.h
if they are to be shared with a process module such as procfs. */
-#define THREAD_FLAG 0x80000000
-#define is_thread(ARG) (((ARG) & THREAD_FLAG) != 0)
-#define is_lwp(ARG) (((ARG) & THREAD_FLAG) == 0)
-#define GET_LWP(PID) TIDGET (PID)
-#define GET_THREAD(PID) TIDGET (PID)
-#define BUILD_LWP(TID, PID) MERGEPID (PID, TID)
-
-#define BUILD_THREAD(TID, PID) (MERGEPID (PID, TID) | THREAD_FLAG)
+#define GET_PID(ptid) ptid_get_pid (ptid)
+#define GET_LWP(ptid) ptid_get_lwp (ptid)
+#define GET_THREAD(ptid) ptid_get_tid (ptid)
+
+#define is_lwp(ptid) (GET_LWP (ptid) != 0)
+#define is_thread(ptid) (GET_THREAD (ptid) != 0)
+
+#define BUILD_LWP(lwp, pid) ptid_build (pid, lwp, 0)
+#define BUILD_THREAD(tid, pid) ptid_build (pid, 0, tid)
/* Pointers to routines from lithread_db resolved by dlopen() */