-
Notifications
You must be signed in to change notification settings - Fork 70
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
feat: Do not use C speedups on Python 3.13+ freethreading #331
base: master
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for your PR!
Please add an entry in CHANGES.rst
describing your change. It should tell that for the time being (at least until the C optimization supports freethreading) the use of the C optimization is disabled automatically in freethreading mode.
Do not enable C speedups by default if running Python 3.13+ in freethreading mode (with GIL disabled). Since the extension does not support this mode explicitly at the moment, loading it would cause CPython to reenable GIL with a warning and penalize the whole environment. Discussed in issue zopefoundation#330.
b3e4385
to
fda90bc
Compare
@tseaver @davisagli I thought that the refactoring of the C code was done to support free threading. Am I wrong here? |
@icemac That's my understanding too. I'll need to find some time to look more closely and see if we just need to declare now that we support it, or if more changes are also needed. |
|
My CLA has just been approved. Should this be merged then, or should I close it pending proper FT support? |
Michał Górny wrote at 2024-10-23 03:07 -0700:
My CLA has just been approved. Should this be merged then, or should I close it pending proper FT support?
I got the impression that Tres and David are interested in full FT support.
Maybe, it will be available soon.
I would say we delay the merging for some time waiting if FT support
will arive soon. If this should not happen, we can merge in a few weeks.
|
Do not enable C speedups by default if running Python 3.13+ in freethreading mode (with GIL disabled). Since the extension does not support this mode explicitly at the moment, loading it would cause CPython to reenable GIL with a warning and penalize the whole environment.
Discussed in issue #330.
I've signed the CLA today, but I suppose it will take some time for it to be processed.