Info Node: (librep.info)Thread Implementation Notes
(librep.info)Thread Implementation Notes
Thread Implementation Notes
---------------------------
The threads used by `librep' are _software threads_. This means that
they are currently implemented by manually switching in and out thread
context (i.e. the call stack) as required. There are a number of
disadvantages to this method:
* blocking I/O blocks _all_ threads, not just the thread doing the
I/O,
* only a single processor is used, thereby avoiding any true
parallelism on multi-processor systems.
The main advantage is the ease of implementation, especially when
retrofitting threads into the previously single-threaded interpreter.