New issue 1989: array.array creation 5x slower than CPython
https://bitbucket.org/pypy/pypy/issue/1989/arrayarray-creation-5x-slower-than-cpython
mike fc:
Creating array.array objects from a buffer seems 5x slower than CPython.
* pypy2 = 3.44s
* pypy3 = 3.42s
* CPython3.4.2 = 0.66
* CPython2.7.9 = 0.69
Using recent nightly for pypy2 and latest release for pypy3 on OSX.
```
#!python
#!/usr/bin/env python
from __future__ import print_function
from datetime import datetime
import array
buf = b"hello there" * 100000
print(len(buf))
start = datetime.now()
for i in range(10000):
p = array.array('B', buf)
delta = datetime.now() - start
print("T:", delta)
```
_______________________________________________
pypy-issue mailing list
[email protected]
https://mail.python.org/mailman/listinfo/pypy-issue