incubator-couchdb-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Alexander Shorin <>
Subject Re: Erlang vs JavaScript
Date Sun, 18 Aug 2013 06:50:32 GMT
On Sun, Aug 18, 2013 at 10:29 AM, Benoit Chesneau <> wrote:
> On Sun, Aug 18, 2013 at 6:51 AM, Thanos Vassilakis <>wrote:
>> Build views performance gains:
>> Python 4-6 times faster + less memory
> Whatever the results of this benchmark are, this not the first time, I
> heard that the python engine is faster than the Javascript one. I wonder
> what could make it faster than the javascript engine. Since the protocol
> and encode/decode steps are the same, this is likely an issue in the
> couchjs program. That would be interesting to see where the JS engine lost
> times and eventually fix it.

As for my experience, Python is not faster than JS until you don't
have to use stdlib or other packages actively. Lack of stdlib power
forces you write/ship a lot of routine code, that mostly not so fast
and effective as some C-extension on disk "that does magic" for
Python. For simple cases like

def map(doc):
  if 'foo' in doc:
    yield doc['foo'], 1

you will not see the profit.


View raw message