[project @ 2001-08-20 13:15:52 by simonmar]
[ghc-hetmet.git] / ghc / includes / SchedAPI.h
index 18c48f5..0a53fa8 100644 (file)
@@ -1,5 +1,5 @@
 /* -----------------------------------------------------------------------------
- * $Id: SchedAPI.h,v 1.9 2000/01/13 14:34:01 hwloidl Exp $
+ * $Id: SchedAPI.h,v 1.13 2001/03/22 03:51:09 hwloidl Exp $
  *
  * (c) The GHC Team 1998
  *
@@ -32,6 +32,9 @@ StgTSO *createThread(nat stack_size, StgInt pri);
 #else
 StgTSO *createThread(nat stack_size);
 #endif
+#if defined(PAR) || defined(SMP)
+void taskStart(void);
+#endif
 void scheduleThread(StgTSO *tso);
 
 static inline void pushClosure   (StgTSO *tso, StgClosure *c) {
@@ -82,7 +85,7 @@ createStrictIOThread(nat stack_size,  StgClosure *closure) {
   t = createThread(stack_size);
 #endif
   pushClosure(t,closure);
-  pushClosure(t,(StgClosure*)&forceIO_closure);
+  pushClosure(t,(StgClosure*)&stg_forceIO_closure);
   return t;
 }
 
@@ -90,14 +93,17 @@ createStrictIOThread(nat stack_size,  StgClosure *closure) {
 /* 
  * Killing threads
  */
-
-void    deleteThread(StgTSO *tso);
-void    deleteAllThreads ( void );
+extern void deleteThread(StgTSO *tso);
+extern void deleteAllThreads ( void );
+extern int  howManyThreadsAvail ( void );
+/*
+ * Run until there are no more threads.
+ */
+extern void finishAllThreads ( void );
 
 /*
  * Reverting CAFs
  */
-
-void RevertCAFs(void);
+extern void RevertCAFs ( void );
 
 #endif