-
-
Notifications
You must be signed in to change notification settings - Fork 32.4k
gh-133931: Introduce _PyObject_XSetRefDelayed to replace Py_XSETREF #134377
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
Changes from 1 commit
09baa04
1ee0825
753df7a
a168de0
e7f6d01
6287322
12a7016
5f42224
388f0ca
8220367
c82e0fb
f99c8f1
5dc24a3
99d2718
7dc6892
e65eb1f
4dbb0a7
d0ba9c9
ae5b6a4
1651fa3
8d309dc
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
- Loading branch information
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -101,6 +101,9 @@ static inline void _PyObject_XDecRefDelayed(PyObject *obj) | |
#endif | ||
|
||
#ifdef Py_GIL_DISABLED | ||
// This is the delayed-free equivalent of Py_XSETREF(), providing the same | ||
// atomic reference assignment semantics but with deferred cleanup suitable | ||
// for concurrent access patterns in free-threaded Python. | ||
corona10 marked this conversation as resolved.
Show resolved
Hide resolved
|
||
PyAPI_FUNC(void) _PyObject_XSetRefDelayed(PyObject **p_obj, PyObject *obj); | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Why not adding this function to There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Because _PyObject_XDecRefDelayed is also declared here? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I think it's fine to place |
||
#else | ||
static inline void _PyObject_XSetRefDelayed(PyObject **p_obj, PyObject *obj) | ||
|
Uh oh!
There was an error while loading. Please reload this page.