~/talk

Advanced Qt - A Deep Dive 4/6 Multithreading Part 2

Talkat Qt Developer Days Munich 2011 · 2011-10-24..10-26· [concurrency, c-and-cpp]
links:none on file
links:none on file
slides:none on file

Explains concrete Qt concurrency patterns: create threads with QThread (run now calls exec by default) or use moveToThread and rely on the event loop, and avoid creating GUI objects off the main thread. Covers synchronization primitives and when to use them: QMutex with QMutexLocker for RAII unlocking, QReadWriteLock (useful only when three or more readers) and QSemaphore/QWaitCondition (wake requires holding a lock). Describes QThreadStorage for per-thread singletons, QAtomicInt for atomic refcounts, and a thumbnail-viewer exercise that fetches images on worker threads.

AI-written summary · about

  1. 0:00Introduction to multithreading
  2. 1:52Synchronization with mutexes
  3. 4:43QMutexLocker convenience class
  4. 6:54Read-write locks explained
  5. 8:35Semaphores in Qt
  6. 10:00Condition variables for waiting
  7. 11:23Thread-local storage
  8. 13:32GUI operations and threads
  9. 15:01Memory management in threads
  10. 16:07Avoid blocking the GUI thread
  11. 17:57Thread safety vs reentrancy
  12. 20:22Implicitly shared types
  13. 21:46Atomic operations
  14. 22:08Canceling thread invocations
  15. 23:58Exercise multithreaded thumbnail viewer
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.