gh-115041: Add wrappers that are atomic only in free-threaded builds#115046
gh-115041: Add wrappers that are atomic only in free-threaded builds#115046colesbury merged 6 commits intopython:mainfrom
Conversation
These are intended to be used in places where atomics are required in free-threaded builds, but not in the default build, and we don't want to introduce the potential performance overhead of an atomic operation in the default build.
|
@corona10 @colesbury - Would you please have a look? I ended up using macros after trying experimenting with some of the changes from #114843. |
corona10
left a comment
There was a problem hiding this comment.
For the naming, I will delegate to @colesbury
2 things:
- If the change does not affect to end-user side, we don't add news.d normally :)
- You may need to update pythoncore.vcxproj and pythoncore.vcxproj.filters for newly added headers.
One of the CI signals will fail without either a NEWS entry or the "skip news" label. I haven't been able to figure out how to add the "skip news" label; I suspect that I'm missing some permissions. I don't feel great about asking folks to review changes with a failing CI signal, even if it's benign, so I've been adding a NEWS entry. Do you know if it would be possible to give me (and other Cinder folks who aren't core devs) permission to add "skip news"? |
You should be promoted to triager, at least. |
|
@colesbury - Would you please take a look at this? This is the last thing we need to sort out before we can merge #113830. |
colesbury
left a comment
There was a problem hiding this comment.
Thanks for doing this Matt. Looks good, but a few things need to be done:
- Fix the merge conflict in Makefile.pre.in
- Add the header to
pythoncore.vcxprojandpythoncore.vcxproj.filters - Probably remove the NEWS file based on @corona10's comments
On (2), my strategy is usually to search for references to a nearby header (e.g., pycore_pyarena.h) in PCbuild/ and use the search results to figure out where to add the references to the new header.
bfe4934 to
b44e1ab
Compare
|
@colesbury @corona10 - I think this should be good to go now. Would you please take a look? |
These are intended to be used in places where atomics are required in free-threaded builds, but not in the default build, and we don't want to introduce the potential performance overhead of an atomic operation in the default build.