python simply not scaleable enough for google?

Alf P. Steinbach alfps at start.no
Thu Nov 12 18:32:28 CET 2009


* Steven D'Aprano:
> On Thu, 12 Nov 2009 08:35:23 -0800, Joel Davis wrote:
> 
>> obviously the GIL is a major reason it's so slow. 


http://en.wikipedia.org/wiki/Global_Interpreter_Lock

Uh oh...


> No such "obviously" about it.
> 
> There have been attempts to remove the GIL, and they lead to CPython 
> becoming *slower*, not faster, for the still common case of single-core 
> processors.
> 
> And neither Jython nor IronPython have the GIL. Jython appears to scale 
> slightly better than CPython, but for small data sets, is slower than 
> CPython. IronPython varies greatly in performance, ranging from nearly 
> twice as fast as CPython on some benchmarks to up to 6000 times slower!
> 
> http://www.smallshire.org.uk/sufficientlysmall/2009/05/22/ironpython-2-0-and-jython-2-5-performance-compared-to-python-2-5/
> 
> http://ironpython-urls.blogspot.com/2009/05/python-jython-and-ironpython.html
> 
> 
> Blaming CPython's supposed slowness

Hm, this seems religious.

Of course Python is slow: if you want speed, pay for it by complexity.

It so happens that I think CPython could have been significantly faster, but (1) 
doing that would amount to creating a new implementation, say, C++Python <g>, 
and (2) what for, really?, since CPU-intensive things should be offloaded to 
other language code anyway.


> on the GIL is superficially plausible 
> but doesn't stand up to scrutiny. The speed of an implementation depends 
> on many factors, and it also depends on *what you measure* -- it is sheer 
> nonsense to talk about "the" speed of an implementation. Different tasks 
> run at different speeds, and there is no universal benchmark.

This also seems religious. It's like in Norway it became illegal to market lemon 
soda, since umpteen years ago it's soda with lemon flavoring. This has to do 
with the *origin* of the citric acid, whether natural or chemist's concoction, 
no matter that it's the same chemical. So, some people think that it's wrong to 
talk about interpreted languages, hey, it should be a "language designed for 
interpretation", or better yet, "dynamic language", or bestest, "language with 
dynamic flavor". And slow language, oh no, should be "language whose current 
implementations are perceived as somewhat slow by some (well, all) people", but 
of course, that's just silly.


Cheers,

- Alf



More information about the Python-list mailing list