]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
gh-117139: Garbage collector support for deferred refcounting (#122956)
authorSam Gross <colesbury@gmail.com>
Thu, 15 Aug 2024 16:09:11 +0000 (12:09 -0400)
committerGitHub <noreply@github.com>
Thu, 15 Aug 2024 16:09:11 +0000 (16:09 +0000)
commite001027188001f4bdf6ea16f70726ca0fabe85c4
tree49ef595c47159c755e5e847f1aac863da92cc330
parent1dad23edbc9db3a13268c1000c8dd428edba29f8
gh-117139: Garbage collector support for deferred refcounting (#122956)

The free-threaded GC now visits interpreter stacks to keep objects
that use deferred reference counting alive.

Interpreter frames are zero initialized in the free-threaded GC so
that the GC doesn't see garbage data. This is a temporary measure
until stack spilling around escaping calls is implemented.

Co-authored-by: Ken Jin <kenjin@python.org>
Include/internal/pycore_frame.h
Include/internal/pycore_gc.h
Include/internal/pycore_stackref.h
Python/frame.c
Python/gc.c
Python/gc_free_threading.c