Details
-
Epic
-
Resolution: Unresolved
-
P3: Somewhat important
-
None
-
None
-
None
-
remove-qatomic
Description
It seems the QAtomic classes have reached the end of their usefulness. The only non-std::atomic-backed implementation is bootstrap (ie. non-atomic), and only moc and automoc remain bootstrapped. So QAtomic is no longer useful as an abstraction of platform-specific atomic operations, esp. seeing as libstdc++, at least, already uses non-locked operations for std::atomic if the application is single-threaded.
At the same time that QAtomic lost its defining meaning, upstream charges ahead and adds wait/notify semantics to every std::atomic in C++20. To gain feature parity, while maintaining compatibility with C++17, we'd need to re-imlement this functionality using futexes. This doesn't seem like a good use of our time.
Therefore, this seems to be a good point time, before somone spends the time to implement QAtomic::wait(), to put QAtomic to rest.
Target should be to remove the classes for Qt 7.
Issues in this epic will define the roadmap until complete removal of the classes.
Attachments
Issue Links
- relates to
-
QTBUG-105467 Impact of C++20 atomics on our code
- Open
- resulted from
-
QTBUG-103466 Update "Implementing Atomic Operations" section
- Closed