[Stackless] Questions and Comments for EuroPython Talk

Andrew Francis andrewfr_ice at yahoo.com
Tue Jun 22 18:34:51 CEST 2010

Hi Folks:

I am doing my second rev of my EuroPython Talk. I will take Richard's advice and make select() a scheduler method rather than a tasklet method. Since I believe this will be the only Stackless talk and I have time, I just want to get my facts right. I have some questions I want to throw out:

1) Why no select in Stackless (Opinion)

My feels are in reality - most stackless applications are I/O driven.
There is a reactor under the hood acting like a select(), therefore
no pressing need. 

I have to confirm this, but I think the motivation for select() in 
Newsqueak came out what to simply monitoring multiple devices in a Windowing system.

1) Relationship between scheduler and OS threads.

In Stackless Python, from reading past posts I believe you can have 
OS threads as well and the tasklets in different threads still can
communicate via channels (in the code there is a tstate and interthread
variable). In short, the scheduler is a singleton. There is a 1 to N relationship between schedulers and OS threads although the
reality is typically one uses only one OS thread? More threads could
be used - but it difficult to take advantage of them.

Again, I think this issue was brought up in the mailing list: the GIL 
and performance issues notwithstanding, what is stopping a future
Stackless Python implementation from moving a tasklet making a potentially
blocking call to a new OS thread?

2) Fairness

I sort of allude to fairness in "Adventures." However Krisjan goes into great lengths about fairness in the 2009 talk "Stackless Python in EVE #2" there is much discussion about fairness. This is opposed to a certain amount of non-determinism in Newsqueak and Go. Could this be a distinguishing philosophical difference in the languages?



More information about the Stackless mailing list