gh-84436: Make Interned Strings Immortal by ericsnowcurrently · Pull Request #102887 · python/cpython · GitHub

github.com

Tin mới

ericsnowcurrently:immortal-interned-strings

GitHub CopilotWrite better code with AI

GitHub Copilot appDirect agents from issue to merge

ActionsAutomate any workflow

CodespacesInstant dev environments

IssuesPlan and track work

Code ReviewManage code changes

Code QualityEnforce quality at merge

GitHub Advanced SecurityFind and fix vulnerabilities

Code securitySecure your code as you build

Secret protectionStop leaks before they start

View all use cases

Financial services

View all industries

Software Development

GitHub SponsorsFund open source developers

Copilot for BusinessEnterprise-grade AI features

Premium SupportEnterprise-grade 24/7 support

Pull requests 2.6k

Security and quality 0

Fixing Copy on Writes from reference counting and immortal objects #84436

awaiting core review

awaiting core review

gh-100227: Make the Global Interned Dict Safe for Isolated Interpreters #102858

Factor out add_threadstate().

Add _PyThreadState_InitDetached().

Add _PyThreadState_ClearDetached().

Add _PyRuntime.cached_objects.main_tstate.

Add _Py_AcquireGlobalObjectsState() and _Py_ReleaseGlobalObjectsState().

Add _Py_AddToGlobalDict().

Drop _Py_AcquireGlobalObjectsState() and _Py_ReleaseGlobalObjectsStat…

Add acquire_global_objects_lock() and release_global_objects_lock().

Add some TODO comments.

Factor out store_interned().

Store a thread state to use just for interned strings.

Always use the main interpreter when possibly resizing the interned d…

Use _PyRuntime.cached_objects.main_tstate instead.

Add _PyThreadState_IsBound() and _PyThreadState_Unbind().

Make sure the one-off tstate is bound before using it.

Use _Py_AcquireGlobalObjectsState() in store_interned().

Use _Py_AddToGlobalDict().

Make objects stored in global containers immortal.

Immortalize the interned strings dict.

github-actions Bot commented Apr 12, 2026

github-actions Bot commented Apr 12, 2026

This PR is stale because it has been open for 30 days with no activity.