[New-bugs-announce] [issue35053] Enhance tracemalloc to trace properly free lists

STINNER Victor report at bugs.python.org
Tue Oct 23 12:42:14 EDT 2018


New submission from STINNER Victor <vstinner at redhat.com>:

CPython uses many "free lists": list of "deallocated" objects which are kept alive to optimize allocation of new objects. For example, the builtin list type has a free list.

Problem: tracemalloc only traces the memory allocation when the object is created, but it doesn't update the traceback when the "free object" is reused to create "a new object".

Attached PR modifies _Py_NewReference() to update the Python traceback in the tracemalloc trace.

----------
components: Library (Lib)
messages: 328326
nosy: vstinner
priority: normal
severity: normal
status: open
title: Enhance tracemalloc to trace properly free lists
versions: Python 3.8

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue35053>
_______________________________________


More information about the New-bugs-announce mailing list