Advanced Qt - A Deep Dive 3/6 Multithreading Part1
summary
Covers Qt’s practical multithreading: use separate threads to keep the GUI responsive and QThread/exec for per-thread event loops, not for heavy parallel CPU work where QtConcurrent is better. Demonstrates QThread/QObject affinity pitfalls (QThread is a QObject so creating timers in the constructor runs them on the wrong thread), shows QThreadPool + QRunnable with releaseThread/reserveThread, warns against subclassing QRunnable from QObject, explains cross-thread signal-slot marshalling, Q_DECLARE_METATYPE/qRegisterMetaType for copies, and using QMetaObject::invokeMethod to return results.
AI-written summary · about
chapters (16)
- 0:00Intro
- 1:24Multithreading
- 1:34Use Cases
- 4:51Do I need multithreading
- 11:35Protections
- 12:30Queued
- 16:25Threat Pools
- 19:35Warnings
- 20:31Thread Pool
- 24:02Sweat Communication
- 24:15Sweat Affinity
- 26:46Event Processing
- 27:49Signal Slot Connections
- 34:11Dont do this
- 38:15Signal Slots
- 42:51QSweat
related talks
58mMultithreading with Qt
01h 00mCreating multithreaded applications with Qt
47m“Multithreading is the answer. What is the question? (part 1 of 2)”
59mAn Introduction to Multithreading in C++20
01h 28mAn Introduction to Multithreading in C++20
01h 04mBack to Basics: Concurrency
01h 03mGet Off My Thread: Techniques for Moving Work to Background Threads
48mDebugging Multithreaded Applications
