Squeak and Active Objects

Tim Rowledge tim at sumeru.stanford.edu
Wed Mar 5 02:19:31 UTC 2003


A trivial and sometimes adequate approach is to schedule a very short
delay in a loop at high priority. This gets to run preemptively over
almost all other proceses, which causes reshuffling of the process
queues for whatever priority _was_ running. i.e. the active process is
suspended and put at the back of its queue, the interrupt is handled,
and the next process on the queue gets a chance to run.

This only works of course if theprocess is inded added to the back of
the queue. In VW for many years (maybe still?) it was put on the front
of the queue. Squeak seems to add to the end.

The main limitation is the granularity of the timer available, so
probably you're limited to no more that a thousand stirs per second.

tim 
-- 
Tim Rowledge, tim at sumeru.stanford.edu, http://sumeru.stanford.edu/tim
Strange OpCodes: AII: Add Insult to Injury



More information about the Squeak-dev mailing list