]> granicus.if.org Git - python/commit
New PYMALLOC_DEBUG function void _PyMalloc_DebugDumpStats(void).
authorTim Peters <tim.peters@gmail.com>
Mon, 1 Apr 2002 06:04:21 +0000 (06:04 +0000)
committerTim Peters <tim.peters@gmail.com>
Mon, 1 Apr 2002 06:04:21 +0000 (06:04 +0000)
commit7ccfadf3a88fb83ffa9cee2a3ff41910aa5a00ec
tree14fe0231a6e07c427226303d6105c77262b25464
parentde14a30d1d70073d36f207fe432e4adad5178399
New PYMALLOC_DEBUG function void _PyMalloc_DebugDumpStats(void).
This displays stats about the # of arenas, pools, blocks and bytes, to
stderr, both used and reserved but unused.

CAUTION:  Because PYMALLOC_DEBUG is on, the debug malloc routine adds
16 bytes to each request.  This makes each block appear two size classes
higher than it would be if PYMALLOC_DEBUG weren't on.

So far, playing with this confirms the obvious:  there's a lot of activity
in the "small dict" size class, but nothing in the core makes any use of
the 8-byte or 16-byte classes.
Include/pymem.h
Objects/obmalloc.c