aboutsummaryrefslogtreecommitdiff
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
commitca6724c16a360b6297d7827cfd0173441ccd95c2 (patch)
tree3e1e58042a222bbe8532507bb67f404be5c9e80f /gdb/sol-thread.c
parent67a659f60e569d0938cb8ce51489514bcf0d4cca (diff)
downloadfsf-binutils-gdb-ca6724c16a360b6297d7827cfd0173441ccd95c2.zip
fsf-binutils-gdb-ca6724c16a360b6297d7827cfd0173441ccd95c2.tar.gz
fsf-binutils-gdb-ca6724c16a360b6297d7827cfd0173441ccd95c2.tar.bz2
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 cf8f33c..f92c49e 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() */