[Stackless] Population simulation in Stackless
aaron at reportlab.com
Sat Aug 24 08:29:14 CEST 2002
sdfrost at UCSD.Edu wrote:
> Dear Aaron,
> Thanks for the link. I've a quick question regarding your scheduler that I
> hope isn't too dumb. When I start it up on a two processor machine, the load
> isn't balanced; I get the equivalent of 1 cpu's worth (which might be 100+0 or
> 90+10 or 65+35). Given that tasktest.py balances just fine, what restricts the
> balancing in world_new?
Dunno. I'm new to stackless myself. "Normal Python" I think has a
"global interpreter lock" which basically guarantees it will never use more
than 1 cpu in the same process. I don't know if Chris did anything to remove
it, but I'd be a little frighted if he did (things like list.append aren't
thread safe). Some time ago Greg Stein determined that fixing this really wasn't
worth the effort (since it added so much overhead everywhere).
I think all of europe is vacationing right now, but maybe when they get
back tanned and rested Chris or someone can explain.
-- Aaron Watters
ps: the best i can say right now is that if you launch 2 of them, both cpus
should fill up ;).
Stackless mailing list
Stackless at www.tismer.com
More information about the Stackless