[tahoe-dev] Debugging memory leaks with guppy
Francois Deppierraz
francois at ctrlaltdel.ch
Sat Oct 23 16:06:46 UTC 2010
Hi Brian,
On 10/22/2010 09:23 AM, Brian Warner wrote:
> Hmmm. Can you locate the ResponseCache instance and look at
> 'self.cache.keys()' ? In particular, I'm interested in the number of
> 'verinfo' values in there:
>>> hp.heap()[0].bysize[0].byid[0].rp
Reference Pattern by <[dict of] class>.
0: _ --- [-] 1 <id 0x65f8e30>: 0x65f8e30
1: a [-] 1 tuple: 0x6d27730*3
2: aa ---- [-] 1 __builtin__.set: 0x67c4050
3: a3 [-] 1 allmydata.util.dictutil.DictOfSets: 0x675a0c0
4: a4 ------ [-] 1 dict of allmydata.mutable.common.ResponseCache:
0x67b4440
5: a5 [-] 1 allmydata.mutable.common.ResponseCache: 0x67b4440
6: a6 -------- [-] 1 dict (no owner): 0x6e9a490*7
7: a7 [+] 1 dict of allmydata.manhole.ModifiedColoredManhole:
0xb9...
8: a6b -------- [+] 1 dict of twisted.conch.manhole.ManholeInterpreter:
0xce...
9: a6c [S] 1 types.FrameType: <<module> at 0x7e4be40>
<Type e.g. '_.more' for more.>
>>> rc = hp.heap()[0].bysize[0].byid[0].rp[5].theone
>>> verinfos = set([verinfo for (verinfo,shnum) in rc.cache.keys()])
>>> len(verinfos)
1
>>>
So there's only one 'verinfo' value there. The size of the cache repr()
is indeed pretty big.
>>> len(repr(rc.cache))
258270546
Gotta go now, but hopefully I'll have a some time tomorrow to follow on.
Cheers,
François
More information about the tahoe-dev
mailing list