C++ Multithreading Part 2: Mutexes and Lock_Guard

Channel:
Subscribers:
2,790
Published on ● Video Link: https://www.youtube.com/watch?v=pi9536nwgK8



Duration: 32:33
176 views
1


Today we finished our introduction to multithreading in C++, with the ability to restrict access to a global data structure via two steps:
1) Moving it inside of a function and making it static
2) Adding two lines of code for a mutex and a lock_guard to restrict the body of the function to just one thread at a time