mirror of
https://github.com/python/cpython.git
synced 2025-08-04 00:48:58 +00:00
bpo-40521: Make context free list per-interpreter (GH-20644)
Each interpreter now has its own context free list: * Move context free list into PyInterpreterState. * Add _Py_context_state structure. * Add tstate parameter to _PyContext_ClearFreeList() and _PyContext_Fini(). * Pass tstate to clear_freelists().
This commit is contained in:
parent
78a02c2568
commit
e005ead49b
7 changed files with 34 additions and 28 deletions
|
@ -1273,10 +1273,7 @@ finalize_interp_types(PyThreadState *tstate, int is_main_interp)
|
|||
}
|
||||
|
||||
_PyAsyncGen_Fini(tstate);
|
||||
|
||||
if (is_main_interp) {
|
||||
_PyContext_Fini();
|
||||
}
|
||||
_PyContext_Fini(tstate);
|
||||
|
||||
/* Cleanup Unicode implementation */
|
||||
_PyUnicode_Fini(tstate);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue