HomeComputer ScienceCPU Scheduling Policy Simulator

🖥️ CPU Scheduling Policies: FCFS, SJF, Priority and Round Robin

Interactive 3D timeline of processes queued for a CPU where switching between FCFS, SJF, priority and round-robin scheduling shows wait times and turnaround times change live.

Computer Science3DModerate60 FPS
cpu-scheduling-policies-lab ↗ Open standalone

A fixed batch of processes with random arrival times and CPU burst lengths is replayed on a live 3D timeline, letting you swap between FCFS, SJF, Priority and Round Robin scheduling and watch queue order, wait time and turnaround time change for the exact same workload.

🔬 What It Demonstrates

Each policy chooses a different next process from the ready queue. The Gantt timeline reveals the resulting execution order live, and the stat panel shows how average wait and turnaround time shift, even though total CPU busy time stays the same.

🎮 How to Use

Pick an algorithm to instantly rebuild the timeline for the current workload. Adjust the Round Robin quantum, change how many processes are in the batch, or generate a brand-new random workload with 🎲.

💡 Did You Know?

Shortest Job First provably minimizes average waiting time for a fixed batch of jobs, but real schedulers rarely use it directly since a process's future burst length usually isn't known in advance — it has to be estimated.

⚙ Under the hood

Interactive 3D process queue where switching between FCFS, SJF, priority and round-robin scheduling shows how each policy changes waiting time and CPU utilization.

cpu-schedulingoperating-systemsround-robinpriority-schedulingprocess-managementcomputer-science

3D · Three.js / WebGL renderer · 60 FPS target · runs fully client-side, no install

What did you find?

Add reproduction steps (optional)