Title: Leak in typeobject.c
Type: resource usage Stage: resolved
Components: Interpreter Core Versions: Python 3.7
Status: closed Resolution: duplicate
Dependencies: Superseder: Reference leaks introduced by bpo-30860
View: 31420
Assigned To: Nosy List: eric.snow, methane, skrah
Priority: normal Keywords:

Created on 2017-09-10 16:04 by skrah, last changed 2017-09-12 11:39 by skrah. This issue is now closed.

Messages (4)
msg301812 - (view) Author: Stefan Krah (skrah) * (Python committer) Date: 2017-09-10 16:04
I traced this valgrind result down to  
2ebc5ce42a8a9e047e790aefbf9a94811569b2b6 :

==23495== 240 (72 direct, 168 indirect) bytes in 1 blocks are definitely lost in loss record 2,255 of 2,922
==23495==    at 0x4C2A9A1: malloc (vg_replace_malloc.c:299)
==23495==    by 0x42C6BC: PyMem_RawMalloc (obmalloc.c:420)
==23495==    by 0x42C6BC: _PyObject_Alloc (obmalloc.c:975)
==23495==    by 0x42C6BC: _PyObject_Malloc (obmalloc.c:985)
==23495==    by 0x448B78: _PyObject_GC_Alloc (gcmodule.c:1629)
==23495==    by 0x448B78: _PyObject_GC_Malloc (gcmodule.c:1651)
==23495==    by 0x448B78: _PyObject_GC_New (gcmodule.c:1663)
==23495==    by 0x4A85B6: new_dict (dictobject.c:584)
==23495==    by 0x4A85B6: PyDict_New (dictobject.c:624)
==23495==    by 0x4AC8F0: PyDict_Copy (dictobject.c:2510)
==23495==    by 0x4D68A7: set_names (typeobject.c:7138)
==23495==    by 0x4D68A7: type_new (typeobject.c:2756)
==23495==    by 0x4CAEC4: type_call (typeobject.c:922)
==23495==    by 0x47344B: _PyObject_FastCallDict (call.c:125)
==23495==    by 0x5497D2: builtin___build_class__ (bltinmodule.c:165)
==23495==    by 0x4725AF: _PyMethodDef_RawFastCallKeywords (call.c:653)
==23495==    by 0x4725AF: _PyCFunction_FastCallKeywords (call.c:726)
==23495==    by 0x4283E0: call_function (ceval.c:4701)
==23495==    by 0x4283E0: _PyEval_EvalFrameDefault (ceval.c:3218)
==23495==    by 0x54D3C6: PyEval_EvalFrameEx (ceval.c:549)
==23495==    by 0x54D3C6: _PyEval_EvalCodeWithName (ceval.c:4049)
msg301814 - (view) Author: Inada Naoki (methane) * (Python committer) Date: 2017-09-10 16:15
Maybe, PyDict_ClearFreeList() is not called?
msg301923 - (view) Author: Eric Snow (eric.snow) * (Python committer) Date: 2017-09-11 22:57
@skrah, could you see if the PR for issue #31420 resolves this?  I'm guessing it won't, but you indicated that the two issues might be related.  Thanks!
msg301950 - (view) Author: Stefan Krah (skrah) * (Python committer) Date: 2017-09-12 11:39
It's fixed, thanks!
Date User Action Args
2017-09-12 11:39:13skrahsetstatus: open -> closed
superseder: Reference leaks introduced by bpo-30860
messages: + msg301950

resolution: duplicate
stage: needs patch -> resolved
2017-09-11 22:57:51eric.snowsetmessages: + msg301923
2017-09-10 16:15:20methanesetnosy: + methane
messages: + msg301814
2017-09-10 16:04:29skrahcreate