Back to projects

Systems · Concurrency · C

Completed

Philosophers

View on GitHub

Implemented the dining philosophers problem using threads, mutexes, synchronization, and monitoring in C.

CPOSIX ThreadsMutexesLinux

Overview

A concurrency project focused on understanding threads, race conditions, synchronization, timing, mutexes, and safe shared-state management.

Challenges

Multiple philosopher threads needed synchronized access to shared forks without introducing data races.

Protected shared resources with mutexes and structured the simulation around controlled synchronization and monitoring.

What I Learned

How threads execute concurrently.

How mutexes protect shared resources.

How race conditions and deadlocks can appear.

How timing affects concurrent programs.

Highlights

Multithreading

Synchronization

Mutexes

Race-condition debugging