Threads vs. continuations

Paul Rubin http
Tue Feb 19 20:10:06 EST 2008


John Nagle <nagle at animats.com> writes:
>     People did things like that to hammer threading onto operating
> systems so dumb they couldn't context switch, like
> DOS, early Windows, and MacOS through 7.  Nobody does that
> any more.

I see stuff heading more the other way; here's a description of a test
of Erlang with 20 million (userspace) threads:

http://groups.google.com/group/comp.lang.functional/msg/33b7a62afb727a4f

I don't know of any OS's that can handle that many threads.
Lightweight userspace threads also makes it sane to do things like
make GUI's with a separate thread per widget, and in general to
handle large numbers of concurrent tasks without the large memory
footprint and context switch overhead of kernel level threads.



More information about the Python-list mailing list