Details
-
Epic
-
Resolution: Unresolved
-
P3: Somewhat important
-
6.4
-
None
-
Qt for Python NoGIL
-
e7770a293 (dev), 5abd98b65 (dev), f09dc73e5 (dev), 33bd61d13 (dev), c866be38d (dev), ab63b7fe0 (6.8), a4790d33c (dev), 72be78063 (6.9), d417218c4 (dev), a3d52a779 (dev), 03de46725 (dev), 5ee9a1f76 (6.9), f489d5b90 (dev), ceb7567c7 (6.9), 7b8592161 (dev)
Description
Overview
Python 3.12 is probably starting to support a no-gil configuration. PySide should to find the necessary changes to enable that in the PySide project. The anticipated community reaction
is quite huge, since that will make Python really performant.
Currently, there is only a prototype implementation that we are using. It is based on Python nogil-3.9.10-1 with a register machine and different opcodes. This version is by no means the version expected for the fall, when Python 3.12 should come into existence with NoGIL.
It is not clear whether this branch will be continued at all. This depends very much
on business decisions. I just wanted to make sure of the feasibility, but I'm not implementing it yet.
The feasibility is definitely there if they have the right people and time.
Areas in need of thread protection
(to be identified by thread sanitizer).
- Potentially many areas in Object deletion (reuse wrapper map lock?)
- libshiboken setParent()/ removeParent() and destruction maintaining lists of children and pointer to parent in SbkObjectPrivate/ParentInfo
- Signal/Slot ConnectionHash in sources/pyside6/libpyside/dynamicslot.cpp:303
- setNextQObjectMemoryAddr() sources/pyside6/libpysideqml/pysideqmlregistertype.cpp:41 (thread_local?)
References
Attachments
Issue Links
- is duplicated by
-
PYSIDE-2776 Free-threaded CPython and PySide
-
- Closed
-
- relates to
-
PYSIDE-1819 PySide GIL locking semantics are undocumented creating deadlock potential
-
- Open
-
-
PYSIDE-1931 Pyside2 app hangs in QSqlQueryModel.setQuery() connecting to database over paramiko/sshtunnel (PostGres)
-
- Closed
-
Gerrit Reviews
For Gerrit Dashboard: PYSIDE-2221 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
459935,26 | WIP: Disable GIL: Implement free threading for Python 3.13 | dev | pyside/pyside-setup | Status: NEW | -2 | 0 |
652346,14 | handover: Save status information of unfinished work | dev | pyside/pyside-setup | Status: NEW | -1 | 0 |
656672,1 | Disable GIL state | dev | pyside/pyside-setup | Status: NEW | +2 | 0 |
657234,1 | WIP: PySide6: Make qobjectNextAddr thread_local | dev | pyside/pyside-setup | Status: NEW | -2 | +1 |
657290,2 | WIP: PySide6: Protect the signal connection hash by a mutex | dev | pyside/pyside-setup | Status: NEW | -2 | 0 |
657957,4 | WIP: PySide6: Suppress warning when doing first signal connection from a thread | dev | pyside/pyside-setup | Status: NEW | -2 | 0 |
458708,3 | nogil: Apply the first necessary fixes | dev | pyside/pyside-setup | Status: MERGED | +2 | 0 |
458908,2 | shiboken: Simplify sys module attribute lookup | dev | pyside/pyside-setup | Status: MERGED | +2 | 0 |
458910,2 | nogil: Adjust the forgiveness enum opcode patch | dev | pyside/pyside-setup | Status: MERGED | +2 | 0 |
459185,2 | NoGIL: Disable all tests which use refcounting | dev | pyside/pyside-setup | Status: ABANDONED | 0 | 0 |
459188,4 | testing: make multiple_feature_test.py less verbose | dev | pyside/pyside-setup | Status: MERGED | +2 | 0 |
459248,2 | NoGIL: Disable opcode tests in enum_test.py | dev | pyside/pyside-setup | Status: MERGED | +2 | 0 |
459936,7 | WIP: NoGIL: Add mutex to protect Bucket | dev | pyside/pyside-setup | Status: ABANDONED | -2 | 0 |
459937,5 | NoGIL: Fix ~ObjectType() to handle children deleted before parents | dev | pyside/pyside-setup | Status: ABANDONED | +1 | 0 |
575418,49 | libpyside: Reimplement signal connections for Python callables not targeting a QMetaMethod | dev | pyside/pyside-setup | Status: MERGED | +2 | 0 |
596712,2 | Fix disconnecting from C functions (qobject_connect_notify_test flakyness) | 6.8 | pyside/pyside-setup | Status: MERGED | +2 | 0 |
596731,3 | Fix disconnecting from C functions (qobject_connect_notify_test flakyness) | dev | pyside/pyside-setup | Status: MERGED | +2 | +1 |
638259,7 | WIP: disable-gil: Make the gilless option thread-safe | dev | pyside/pyside-setup | Status: ABANDONED | -2 | 0 |
638264,4 | PySide/Signal manager: Fix corruption when connecting to temporary object | dev | pyside/pyside-setup | Status: MERGED | +2 | 0 |
640524,2 | PySide/Signal manager: Fix corruption when connecting to temporary object | 6.9 | pyside/pyside-setup | Status: MERGED | +2 | 0 |
646660,2 | shiboken6/Bucket test: Use an atomic<bool> | dev | pyside/pyside-setup | Status: MERGED | +2 | +1 |
646876,11 | testing: fix finding tests on new cmake versions | dev | pyside/pyside-setup | Status: MERGED | +2 | 0 |
647383,4 | shiboken: fix windows glitch on limited-api=no | dev | pyside/pyside-setup | Status: MERGED | +2 | 0 |
647442,1 | shiboken: fix windows glitch on limited-api=no | 6.9 | pyside/pyside-setup | Status: ABANDONED | 0 | 0 |
647549,2 | testing: fix finding tests on new cmake versions | 6.9 | pyside/pyside-setup | Status: MERGED | +2 | 0 |
656789,3 | Output more detailed build in QLibraryInfo::build() | dev | pyside/pyside-setup | Status: MERGED | +2 | 0 |
657217,2 | Output more detailed build in QLibraryInfo::build() | 6.9 | pyside/pyside-setup | Status: MERGED | +2 | 0 |
657533,4 | build system: Extend sanitizer support | dev | pyside/pyside-setup | Status: MERGED | +2 | 0 |