/* -----------------------------------------------------------------------------
- * $Id: PrimOps.h,v 1.83 2001/09/24 00:22:59 ken Exp $
+ * $Id: PrimOps.h,v 1.84 2001/10/27 22:05:48 sof Exp $
*
* (c) The GHC Team, 1998-2000
*
#define myThreadIdzh(t) (t = CurrentTSO)
extern int cmp_thread(const StgTSO *tso1, const StgTSO *tso2);
+extern int rts_getThreadId(const StgTSO *tso);
/* ------------------------------------------------------------------------
Parallel PrimOps
/* ---------------------------------------------------------------------------
- * $Id: Schedule.c,v 1.102 2001/10/23 11:28:51 simonmar Exp $
+ * $Id: Schedule.c,v 1.103 2001/10/27 22:05:48 sof Exp $
*
* (c) The GHC Team, 1998-2000
*
}
/* ---------------------------------------------------------------------------
+ * Fetching the ThreadID from an StgTSO.
+ *
+ * This is used in the implementation of Show for ThreadIds.
+ * ------------------------------------------------------------------------ */
+int rts_getThreadId(const StgTSO *tso)
+{
+ return tso->id;
+}
+
+/* ---------------------------------------------------------------------------
Create a new thread.
The new thread starts with the given stack size. Before the