3.4 seems happier:
asottile@work:/tmp$ rm *.pyc; python3.4 repro.py
ready
<module 'city_hoods' from '/tmp/city_hoods.py'>
77472
VmHWM: 77472 kB
VmRSS: 65228 kB
asottile@work:/tmp$ python3.4 repro.py
ready
<module 'city_hoods' from '/tmp/city_hoods.py'>
77472
VmHWM: 77472 kB
VmRSS: 65232 kB
The nasty result above is from 2.7:
$ python
Python 2.7.6 (default, Mar 22 2014, 22:59:56)
[GCC 4.8.2] on linux2
3.3 also seems to have the same exaggerated problem:
$ rm *.pyc -f; python3.3 repro.py
ready
<module 'city_hoods' from '/tmp/city_hoods.py'>
1112996
VmHWM: 1112996 kB
VmRSS: 133468 kB
asottile@work:/tmp$ python3.3 repro.py
ready
<module 'city_hoods' from '/tmp/city_hoods.py'>
81392
VmHWM: 81392 kB
VmRSS: 69304 kB
$ python3.3
Python 3.3.6 (default, Jan 28 2015, 17:27:09)
[GCC 4.8.2] on linux
So seems the leaky behaviour was fixed at some point, any ideas of what change fixed it and is there a possibility of backporting it to 2.7? |