Suitability for long-running text processing?

Felipe Almeida Lessa felipe.lessa at gmail.com
Mon Jan 8 11:01:08 EST 2007


On 1/8/07, tsuraan <tsuraan at gmail.com> wrote:
[snip]
> The loop is deep enough that I always interrupt it once python's size is
> around 250 MB.  Once the gc.collect() call is finished, python's size has
> not changed a bit.
[snip]
> This has been tried under python 2.4.3 in gentoo linux and python 2.3 under
> OS X.3.  Any suggestions/work arounds would be much appreciated.

I just tried on my system

(Python is using 2.9 MiB)
>>> a = ['a' * (1 << 20) for i in xrange(300)]
(Python is using 304.1 MiB)
>>> del a
(Python is using 2.9 MiB -- as before)

And I didn't even need to tell the garbage collector to do its job. Some info:

$ cat /etc/issue
Ubuntu 6.10 \n \l

$ uname -r
2.6.19-ck2

$ python -V
Python 2.4.4c1

-- 
Felipe.



More information about the Python-list mailing list