[Python-ideas] Exploration PEP : Concurrency for moderately massive (4 to 32 cores) multi-core architectures

Clark Maurer cmaurer at slickedit.com
Thu Sep 27 23:34:11 CEST 2007



I've been following this discussion.  My thoughts mostly reiterate what
has already been said.  There's no way to get rid of the GIL without
significantly effecting single threaded performance.  IMO getting rid of
the GIL would require writing a mark-and-sweep algorithm.  To improve
performance you can do incremental (threaded) marking and detect page
faults so that modified pages can be rescanned for references. The Boehm
garbage collector does this (I think) but Python would need something
much more custom.  This type of garbage collector is VERY hard to write.
Worse yet, the current implementation of Python would need a lot of


FYI: I tried using the Boehm collector in SlickEdit and it leaked memory
like crazy.  I never figured out why but I suspect it had to do with it
treating everything in memory as a potential pointer.


Ruby's mark-and sweep garbage collector illustrates the loss in single
threaded performance and since it does its own thread scheduling, the
thread performance is bad too. 


As Python stands right now, its performance is excellent for single
threading, the implementation is simple, it works well for the typical
Python user, and using processes at least gives a work around.  I like
to be a perfectionist as much as the next guy but the pay back doesn't
warrant the level of effort.  Where's the easy button when you need oneJ


I thought you Python enthusiasts (especially Guido) might enjoy the
article I just posted on the SlickEdit blog.  I'm the CTO and founder of
SlickEdit. I hate saying that because I'm a very humble guy but I
thought you would want to know.  The article is called "Comparing Python
to Perl and Ruby", go to  http://blog.slickedit.com/.   I limited the
article to a simple grammar comparison because I wanted to keep the
article short.  Hope you enjoy it.


Guido, I have another article written which talks about Python as well
but I have not yet posted it.  If you give me an email address, I will
send it to you to look over before I post it.  Don't give me your email
address here.  Instead write to support at slickedit.com and let them know
that I requested your email address.





-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-ideas/attachments/20070927/55066519/attachment.html>

More information about the Python-ideas mailing list