summaryrefslogtreecommitdiff
path: root/rts/Schedule.h
diff options
context:
space:
mode:
authorSimon Marlow <simonmar@microsoft.com>2006-06-16 10:33:42 +0000
committerSimon Marlow <simonmar@microsoft.com>2006-06-16 10:33:42 +0000
commitb1953bbb1ed3cb16497e5447db7487f0c2d9e41a (patch)
treedf9e129c57b586a952634dc080939b621ae64cf8 /rts/Schedule.h
parent1e3d53b4707a6c9c7c99cdaa54e3646b840f5cc9 (diff)
downloadhaskell-b1953bbb1ed3cb16497e5447db7487f0c2d9e41a.tar.gz
Asynchronous exception support for SMP
This patch makes throwTo work with -threaded, and also refactors large parts of the concurrency support in the RTS to clean things up. We have some new files: RaiseAsync.{c,h} asynchronous exception support Threads.{c,h} general threading-related utils Some of the contents of these new files used to be in Schedule.c, which is smaller and cleaner as a result of the split. Asynchronous exception support in the presence of multiple running Haskell threads is rather tricky. In fact, to my annoyance there are still one or two bugs to track down, but the majority of the tests run now.
Diffstat (limited to 'rts/Schedule.h')
-rw-r--r--rts/Schedule.h23
1 files changed, 1 insertions, 22 deletions
diff --git a/rts/Schedule.h b/rts/Schedule.h
index e30e911e68..f82946e831 100644
--- a/rts/Schedule.h
+++ b/rts/Schedule.h
@@ -55,24 +55,7 @@ void wakeUpRts(void);
* Called from STG : yes
* Locks assumed : we own the Capability.
*/
-StgTSO * unblockOne(Capability *cap, StgTSO *tso);
-
-/* raiseAsync()
- *
- * Raises an exception asynchronously in the specified thread.
- *
- * Called from STG : yes
- * Locks assumed : none
- */
-void raiseAsync(Capability *cap, StgTSO *tso, StgClosure *exception);
-
-/* suspendComputation()
- *
- * A variant of raiseAsync(), this strips the stack of the specified
- * thread down to the stop_here point, leaving a current closure on
- * top of the stack at [stop_here - 1].
- */
-void suspendComputation(Capability *cap, StgTSO *tso, StgPtr stop_here);
+StgTSO * unblockOne (Capability *cap, StgTSO *tso);
/* raiseExceptionHelper */
StgWord raiseExceptionHelper (StgRegTable *reg, StgTSO *tso, StgClosure *exception);
@@ -176,8 +159,6 @@ extern rtsBool blackholes_need_checking;
extern Mutex RTS_VAR(sched_mutex);
#endif
-StgBool isThreadBound(StgTSO *tso);
-
SchedulerStatus rts_mainLazyIO(HaskellObj p, /*out*/HaskellObj *ret);
/* Called by shutdown_handler(). */
@@ -198,8 +179,6 @@ void print_bq (StgClosure *node);
void print_bqe (StgBlockingQueueElement *bqe);
#endif
-void labelThread(StgPtr tso, char *label);
-
/* -----------------------------------------------------------------------------
* Some convenient macros/inline functions...
*/