Skip to content

Operating Systems

CHRONORIFT

Multi-process OS game engine demonstrating bare-metal concurrency and IPC.

C++POSIXpthreadsDockerLinux SyscallsSIGUSR1shm_open

OVERVIEW

A multi-process turn-based RPG engineered to demonstrate complex operating system principles, concurrency, and bare-metal resource management. Every game mechanic maps directly to an OS concept — thread scheduling, IPC, signal handling, and deadlock detection.

KEY HIGHLIGHTS

  • 013 isolated Linux processes communicating exclusively via POSIX shared memory and unnamed semaphores
  • 02Custom stamina-based temporal scheduler with SIGUSR1 signal-based stun and full state recovery
  • 03Background deadlock detector using wait-for graph over shared artifact resources

TECHNICAL IMPLEMENTATION

01

Multi-Process IPC Architecture

Architected the game across 3 isolated Linux processes: a Game Arbiter, a Human Interfacing Process, and an Automated Strategic Process. All inter-process communication was performed exclusively via POSIX Shared Memory (shm_open) and unnamed semaphores. Pipe-based IPC was explicitly forbidden in the spec, requiring a deeper system-level solution.

02

Concurrency & Scheduling

Implemented a thread-per-NPC concurrency model utilizing a custom stamina-based temporal scheduler to enforce serial action execution across concurrently accumulating entity threads. Engineered a POSIX signal-based stun mechanic (SIGUSR1) for asynchronous thread suspension with full state recovery on resume.

03

Resource Management

Developed a background deadlock detector using a wait-for graph algorithm over shared artifact resources, continuously monitoring lock acquisition order to detect circular waits. Built a contiguous memory allocator for a 20-slot inventory system handling fragmentation and swap-in/swap-out to long-term storage.

TECH STACK

C++POSIXpthreadsDockerLinux SyscallsSIGUSR1shm_open
← PREVAVAL SYSTEMSNEXT →CITYMIND