[Haskell-cafe] concurrent haskell: thread priorities

Neal Alexander wqeqweuqy at hotmail.com
Mon Dec 22 15:07:32 EST 2008


 From what i understand (correct me if I'm wrong):

The threaded RT creates an OS thread for each CPU/core on the system and 
uses them to multiplex userland threads. These are context switched 
whenever they block/yield/gc and no priorities can be assigned.

It seems like we could get some priority based scheduling (and still be 
slackers) if we allow marked green threads to be strictly associated 
with a specific OS thread (forkChildIO?).


Its not a very good solution, but it seems easy to implement and would 
be nice for the few problems that really need priority based scheduling.

How many of those problems involve having 1 thread running at 
high/realtime priority? Maybe most?



More information about the Haskell-Cafe mailing list