New submission from mikefc <[email protected]>:

OSX. 4 core i5.  recent 'nightly' version of pypy

Time to run the code for cpython and pypy.

          map    multiprocessing.map
CPython   28.9          12.6
pypy      28.1          23.9

#-------------------------------------------------------
# code code code code code
#-------------------------------------------------------
import hashlib
import datetime
import multiprocessing

def f(i):
    return hashlib.md5("hello %i" % i).hexdigest()

p = multiprocessing.Pool(4)

for mapf in (map, p.map):
    start = datetime.datetime.now()
    mapf(f, xrange(2**23))
    print datetime.datetime.now() - start

----------
messages: 5932
nosy: mikefc, pypy-issue
priority: performance bug
status: unread
title: multiprocessing slower than cpython

________________________________________
PyPy bug tracker <[email protected]>
<https://bugs.pypy.org/issue1538>
________________________________________
_______________________________________________
pypy-issue mailing list
[email protected]
http://mail.python.org/mailman/listinfo/pypy-issue

Reply via email to