Issue #1783: 50x higher memory usage with array.array (compared to CPython) (pypy/pypy)

New issue 1783: 50x higher memory usage with array.array (compared to CPython) https://bitbucket.org/pypy/pypy/issue/1783/50x-higher-memory-usage-with-arra... Konstantin Lopuhin: I am trying to initialize a large array with an iterator (for example, where all values are zero initially), and PyPy consumes much more memory than CPython: ``` #!bash $ python Python 2.7.6 (v2.7.6:3a1db0d2747e, Nov 10 2013, 00:42:54) [GCC 4.2.1 (Apple Inc. build 5666) (dot 3)] on darwin $ /usr/bin/time -l python -c "from array import array; array('b', (0 for _ in xrange(10000000)))" 1.52 real 1.50 user 0.01 sys 14954496 maximum resident set size 0 average shared memory size 0 average unshared data size 0 average unshared stack size 4131 page reclaims 0 page faults 0 swaps 0 block input operations 0 block output operations 0 messages sent 0 messages received 0 signals received 0 voluntary context switches 7 involuntary context switches $ pypy Python 2.7.6 (394146e9bb67, May 08 2014, 16:45:59) [PyPy 2.3.0 with GCC 4.2.1 Compatible Apple LLVM 5.0 (clang-500.2.79)] on darwin $ /usr/bin/time -l pypy -c "from array import array; array('b', (0 for _ in xrange(10000000)))" 1.47 real 1.13 user 0.32 sys 736083968 maximum resident set size 0 average shared memory size 0 average unshared data size 0 average unshared stack size 223518 page reclaims 1 page faults 0 swaps 0 block input operations 20 block output operations 0 messages sent 0 messages received 0 signals received 0 voluntary context switches 4 involuntary context switches ```
participants (1)
-
Konstantin Lopuhin