string issue or questions about intern
Brian Kelley
kelley at bioreason.com
Fri Jul 14 06:27:11 EDT 2000
How can you tell what's in the intern table?
This is really in response to the thread "Is pickle buggy?" where we are
trying to trace down a memory leak.
Jepler epler has an example piece of code:
while 1:
eval(`uniquestring()`)
where unique string returns a unique 5 character string per call. This
appears to run out of memory after a while on his linux box and on my NT
box.
now if uniquestring returns something like 'a="AAAAA"'
while 1:
eval(`uniquestring()`)
Memory stays constant.
So, does eval('"AAAAA"') intern "AAAAA" or simply not clean up the
memory since it is not assigned to a variable?
And does this have anything to do with a potential memory leak in
pickle? (See the thread if you are interested)
--
Brian Kelley Bioreason, Inc
505 995-8188 ext 207 150 Washington St Suite 303
kelley at bioreason.com Santa Fe, NM, 87501
More information about the Python-list
mailing list