-
-
Notifications
You must be signed in to change notification settings - Fork 32.2k
gh-123619: Add an unstable C API function for enabling deferred reference counting #123635
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from 6 commits
Commits
Show all changes
38 commits
Select commit
Hold shift + click to select a range
7107103
Implement PyUnstable_Object_SetDeferredRefcount
ZeroIntensity 3928ea6
Update documentation.
ZeroIntensity 6d2d34e
Add docstring.
ZeroIntensity 6af0adf
Add NEWS entry.
ZeroIntensity 1cc3aae
Fix indentation.
ZeroIntensity fd087a5
Fix hyperlink reference.
ZeroIntensity 2dacc0d
Update object.c
ZeroIntensity 0c8b98d
Update object.rst
ZeroIntensity 50ff96e
Rename to EnableDeferredRefcount
ZeroIntensity 6be9286
No-op if the object already has DRC enabled
ZeroIntensity 10f3a2d
Fix indentation.
ZeroIntensity 78889d5
Use 1 for success.
ZeroIntensity fe2cb46
Remove redundant line.
ZeroIntensity 7b95459
Add simple unit test.
ZeroIntensity 042f610
Make thread-safe.
ZeroIntensity c1d9c74
Fix test.
ZeroIntensity a88aa31
Add owned-by-current-thread check back.
ZeroIntensity 3f31693
Use atomic storage for ob_ref_shared
ZeroIntensity cedf106
No-op if the object is not a GC type.
ZeroIntensity b5f8df6
Update the documentation.
ZeroIntensity 7e2653a
Update the docstring.
ZeroIntensity b831c77
Clarify thread safety in the documentation.
ZeroIntensity d0b5ed2
Fix thread safety on GC bits.
ZeroIntensity f2b2c78
Retain old reference count.
ZeroIntensity 5728bc3
Require CPU resources for tests.
ZeroIntensity e6dd1f7
Fix typo.
ZeroIntensity 85ce7dd
Add a what's new entry.
ZeroIntensity 51a8a30
Merge branch 'main' into api-deferred-rc
ZeroIntensity 1e4413f
Remove extra newline.
ZeroIntensity b57078c
Merge branch 'api-deferred-rc' of https://github.com/ZeroIntensity/cp…
ZeroIntensity 99e9b64
Fix retainment of shared reference count.
ZeroIntensity d8e8af8
Update object.rst
ZeroIntensity 7b3510d
Update object.rst
ZeroIntensity 4c29547
Update Doc/c-api/object.rst
ZeroIntensity 55443b6
Use _Py_atomic_add_ssize instead of store.
ZeroIntensity 00debea
Merge branch 'api-deferred-rc' of https://github.com/ZeroIntensity/cp…
ZeroIntensity 1a20d14
Don't load the GC bits more than once.
ZeroIntensity 93e1030
Merge in the main branch
encukou File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
2 changes: 2 additions & 0 deletions
2
Misc/NEWS.d/next/C_API/2024-09-03-13-33-33.gh-issue-123619.HhgUUI.rst
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
Added the :c:func:`PyUnstable_Object_SetDeferredRefcount` function for | ||
enabling :pep:`703` deferred reference counting. |
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
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.