Thread synchronization is easier said then done. If you use a library like pthread for multithreading and mutexes, then you're probably going to be okay. But, if you're writing your own RTOS, figuring out how mutexes work under the hood is really important.
Mutexes work under the hood in your OS using atomic operations on the computer processor. Atomic Operations are operations on the CPU that cannot be interrupted and are therefore immune to a race condition.
🔥🔥🔥 SOCIALS 🔥🔥🔥
Low Level Merch!: https://www.linktr.ee/lowlevellearning
Follow me on Twitter: https://twitter.com/LowLevelTweets
Follow me on Twitch: https://twitch.tv/lowlevellearning
Join me on Discord!: https://discord.gg/gZhRXDdBYY