From 49526f48fc73d3ccdf09d466ed2d39a30e4df9b9 Mon Sep 17 00:00:00 2001 From: David Malcolm Date: Fri, 22 Jun 2012 14:55:41 -0400 Subject: Issue #14785: Add sys._debugmallocstats() to help debug low-level memory allocation issues --- Objects/frameobject.c | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'Objects/frameobject.c') diff --git a/Objects/frameobject.c b/Objects/frameobject.c index 929385fe28..808e595157 100644 --- a/Objects/frameobject.c +++ b/Objects/frameobject.c @@ -955,3 +955,13 @@ PyFrame_Fini(void) Py_XDECREF(builtin_object); builtin_object = NULL; } + +/* Print summary info about the state of the optimized allocator */ +void +_PyFrame_DebugMallocStats(FILE *out) +{ + _PyDebugAllocatorStats(out, + "free PyFrameObject", + numfree, sizeof(PyFrameObject)); +} + -- cgit v1.2.1