gh-84436: Implement Immortal Objects by eduardo-elizondo · Pull Request #19474 · python/cpython · GitHub

github.com

Tin mới

eduardo-elizondo:immortal-references

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

Implement Immortal Instances

Bypass immortality in NewReference

Add News and Fix MSVC Build

Skip test for MSVC

Skip test for MSVC 32 & 64

Skip all tests for Windows

C-API Improvement Docs

Also looping in @vstinner. Finally got around upstreaming this patch since you recently wrote about this on your C-API Improvement Docs

View reviewed changes

Learn more about hiding disruptive comments

The reason will be displayed to describe this comment to others. Learn more.

Immortalize known immortals

Substantial Performance Regression of Dict operations in Python 3.12.0rc1 versus Python 3.11.4 #109049

[PythonDev] Don't dereference None when creating pandas dataframe duckdb/duckdb#9127

Memory leak on executables embedded with 3.13 #113055

Avoid (some) incref/decref immortality checks on 3.12+ mypyc/mypyc#1044

tagging the pointers

biased reference counts

two most significant bits

@ariago Thanks for the reply, just went through it in detail. First of all, pretty much all of what you are saying in the first message is correct, though there are some additional details that would help complement what

gh-113190: Reenable non-debug interned string cleanup #113601

Interned strings are immortal, despite what the documentation says #113993

View reviewed changes

GH-115776: Embed the values array into the object, for "normal" Python objects. #116115