Week 29: CST 334 - Operating Systems
WK05: Weekly Learning Reflection This week we covered four main topics: Concurrency, Thread API, Locks, and Lock-based Data Structures. Concurrency introduced the idea that multiple tasks can overlap in time, even if only one runs at a time on a single CPU. I learned how unpredictable a program can become when threads share data without proper control, and how race conditions appear when two threads access the same data at the same time. The Thread API section helped me understand how threads are created, joined, and managed in code. I liked seeing how these functions make it possible for a single process to do many things at once, as long as we handle synchronization carefully. Locks were one of the most interesting topics. A lock prevents multiple threads from entering the same critical section at the same time, which helps avoid corrupted data. However, it also made me realize that using locks correctly is not always simple. We must think about fairness, performance, and what ...