An Introduction to Multithreading in C++20
Offered By: CppCon via YouTube
Course Description
Overview
Explore multithreading in C++20 through this comprehensive conference talk from CppCon 2022. Dive into the fundamental tools and techniques for writing safe and efficient multithreaded programs. Learn about thread management, cancellation mechanisms, communication between threads, and synchronization primitives. Discover how to leverage C++20 features like jthread, stop tokens, latches, barriers, futures, and atomics. Gain insights into avoiding common pitfalls such as data races and deadlocks. Apply Amdahl's Law to understand performance gains in parallel algorithms and thread pools. Benefit from the expertise of Anthony Williams, a seasoned C++ developer and author specializing in multithreaded applications and libraries.
Syllabus
Introduction
Agenda
Why Multithreading
Amdahls Law
Parallel Algorithms
Thread Pools
Starting and Managing Threads
Cancelling Threads
Stop Requests
Stoppable
StopCallback
JThread
Destructor
Thread
References
Structure semantics
Stop source
Stop source API
Communication
Data Race
Latch
Constructor
Functions
Tests
Barrier
Structural Barrier
Template
Completion Function
Barrier Function
Futures
Promise
Future
Waiting
Promises
Exception
Async
Shared Future
Mutex
Does it work
Explicit destruction
Deadlock
Waiting for data
Busy wait
Unique lock
Notification
Semaphore
Number of Slots
Atomics
LockFree
Summary
Taught by
CppCon
Related Courses
Android Threads: Getting StartedPluralsight Threading in C#
LinkedIn Learning Modern C++ Concurrency in Depth ( C++17/20)
Udemy Java EE: Concurrency and Multithreading
LinkedIn Learning Parallel and Concurrent Programming with C++ Part 2
LinkedIn Learning