Example of gcc and clang thread sanitizer to detect data race - Introduction to Concurrency in C++

Опубликовано: 10 Октябрь 2024
на канале: Mike Shah
5,220
163

►Full Series Playlist:    • Modern C++ (cpp) Concurrency  
►Find full courses on: https://courses.mshah.io/
►Join as Member to Support the channel:    / @mikeshah  

►Git Repo: https://github.com/MikeShah/moderncpp...
►Lesson Description: In this lesson I show you how to use the thread sanitzer provided in both gcc and clang compilers. Using the thread sanitizers can help save you time debugging programs at scale for thread related errors.

Some helpful links to documentation:
1. https://gcc.gnu.org/onlinedocs/gcc/In...
2. https://clang.llvm.org/docs/ThreadSan...

00:00 Recap on threaded code with a data race
1:39 Introduction to thread sanitizers
3:14 g++ thread sanitizer usage
5:20 clang thread sanitizer usage
6:10 Conclusion, use your tools!

►YouTube Channel:    / mikeshah  
►Please like and subscribe to help the channel!