Hi Christian:


From: Christian Tismer <tismer@stackless.com>
To: Armin Rigo <arigo@tunes.org>
Cc: Andrew Francis <andrewfr_ice@yahoo.com>; "stackless@stackless.com" <stackless@stackless.com>; PyPy Developer Mailing List <pypy-dev@python.org>
Sent: Wednesday, April 4, 2012 6:47 AM
Subject: Re: [pypy-dev] The Work Plan Re: STM proposal funding

...

>Anyway, the underlying ideas have similarities that make me think a lot.

>Thinking of Stackless, I was looking for a way to isolate tasklets in
>a way to let them run in parallel, as long as they are independent.

>In STM, independence is enforced, currently at a relatively high
>price.

>If Stackless were able to provide some better isolation by design,
>maybe there could be a hybrid approach, where most operations would
>not need to rely on STM all the time?

>Just rolling ideas out  -- Chris

The idea I like the most is to use STM and lock-free algorithms for the implementation of the
channels themselves. Again, the Scalable Join Patterns and Parallel ML  papers are the inspiration
for this approach. In contrast I have looked at Go's channel implementation and it has to do stuff like sorting to get the correct locking order.  What I like is that the approach assumes that Stackless programmers know how to write programmes that are fairly isolated.

One  could experiment with this approach using the low-level rstm module or prototypes written in C using
existing STM and lock-free libraries.

Cheers,
Andrew