FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

gh-139103: Defer reference count mutable class attributes by johng · Pull Request #155876 · python/cpython · GitHub

/ cpython Public

gh-139103: Defer reference count mutable class attributes - #155876

Open
johng wants to merge 2 commits into
python:mainfrom
johng:worktree-ft-scaling-139103
Open

gh-139103: Defer reference count mutable class attributes#155876
johng wants to merge 2 commits into
python:mainfrom
johng:worktree-ft-scaling-139103

Conversation

johng commented Aug 15, 2026
edited by bedevere-app Bot
Loading

Copy link
Copy Markdown
Contributor

Mutable class attributes would not scale with more threads, adding defered reference counting to resolve it.

./python_main.exe Tools/ftscalingbench/ftscalingbench.py class_attribute Running benchmarks with 18 threads
class_attribute 6.3x slower

./python.exe Tools/ftscalingbench/ftscalingbench.py class_attribute Running benchmarks with 18 threads
class_attribute 8.0x faster

Mutable class attributes would not scale with more
threads, adding defered reference counting to resolve it.

./python_main.exe Tools/ftscalingbench/ftscalingbench.py class_attribute
Running benchmarks with 18 threads
class_attribute            6.3x slower

./python.exe Tools/ftscalingbench/ftscalingbench.py class_attribute
Running benchmarks with 18 threads
class_attribute            8.0x faster
johng marked this pull request as ready for review August 15, 2026 23:33

johng commented Aug 16, 2026

Copy link
Copy Markdown
Contributor Author

Happy to create a new issue for this if the linked one is not close enough

This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant


Back | FazBrowse Home | New Git URL