about summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorKartik K. Agaram <vc@akkartik.com>2015-01-21 02:13:39 -0800
committerKartik K. Agaram <vc@akkartik.com>2015-01-21 02:13:39 -0800
commite612b44f76e6ab450d82bd34b584053052bd44af (patch)
treebe055021da5ecc6f5384c9d6f923e11fb4af737d
parent79ca54b3d2e74ee7789437fbae9249fb88927f96 (diff)
downloadmu-e612b44f76e6ab450d82bd34b584053052bd44af.tar.gz
597
-rw-r--r--mu.arc8
-rw-r--r--mu.arc.t14
2 files changed, 14 insertions, 8 deletions
diff --git a/mu.arc b/mu.arc
index f482bbcd..e100d089 100644
--- a/mu.arc
+++ b/mu.arc
@@ -205,14 +205,6 @@
 
 ;; managing concurrent routines
 
-; todo: test that restarting a routine works
-;   when it died
-;   when it timed out
-;   when it completed
-; test that run checks status of sleep
-; run multiple routines in tandem
-; drop helper bit in component under test -- comment
-
 (on-init
 ;?   (prn "-- resetting memory allocation")
   (= Memory-allocated-until 1000))
diff --git a/mu.arc.t b/mu.arc.t
index 801609b2..a617ec3a 100644
--- a/mu.arc.t
+++ b/mu.arc.t
@@ -2558,6 +2558,12 @@
 (when (~empty completed-routines*)
   (prn "F - scheduler ignores sleeping but ready threads when detecting deadlock"))
 
+; Helper routines are just to sidestep the deadlock test; they stop running
+; when there's no non-helper routines left to run.
+;
+; Be careful not to overuse them. In particular, the component under test
+; should never run in a helper routine; that'll make interrupting and
+; restarting it very brittle.
 (reset)
 (new-trace "scheduler-helper")
 (= traces* (queue))
@@ -2960,6 +2966,14 @@
   ))
 ;? (quit)
 
+; todo: Haven't yet written several tests
+;   that restarting a routine works
+;     when it died
+;     when it timed out
+;     when it completed
+;   running multiple routines in tandem
+; first example using these features: read-move-incomplete in chessboard-cursor.arc.t
+
 ; The scheduler needs to keep track of the call stack for each routine.
 ; Eventually we'll want to save this information in mu's address space itself,
 ; along with the types array, the magic buffers for args and oargs, and so on.