]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
bpo-42745: Make the type cache per-interpreter (GH-23947)
authorVictor Stinner <vstinner@python.org>
Sat, 26 Dec 2020 00:45:43 +0000 (01:45 +0100)
committerGitHub <noreply@github.com>
Sat, 26 Dec 2020 00:45:43 +0000 (01:45 +0100)
commit41010184880151d6ae02a226dbacc796e5c90d11
tree5d87ed2b4392de3d7063b59f03d955b04f8b0eec
parent77fde8dc16dc808b9f9838af1aa1253e15cab6ad
bpo-42745: Make the type cache per-interpreter (GH-23947)

Make the type attribute lookup cache per-interpreter.

Add private _PyType_InitCache() function, called by PyInterpreterState_New().

Continue to share next_version_tag between interpreters, since static
types are still shared by interpreters.

Remove MCACHE macro: the cache is no longer disabled if the
EXPERIMENTAL_ISOLATED_SUBINTERPRETERS macro is defined.
Include/internal/pycore_interp.h
Include/internal/pycore_object.h
Include/internal/pycore_pylifecycle.h
Misc/NEWS.d/next/Core and Builtins/2020-12-25-23-30-58.bpo-42745.XsFoHS.rst [new file with mode: 0644]
Objects/typeobject.c
Python/pylifecycle.c
Python/pystate.c