CS3502/project2
2025-12-04 18:03:57 -05:00
..
report feat: project 3 2025-12-04 18:03:57 -05:00
src add: project 2 2025-10-28 22:15:17 -04:00
test fix(test): silence command to check for Nix 2025-11-01 22:33:06 -04:00
default.nix add: project 2 2025-10-28 22:15:17 -04:00
Makefile add: project 2 2025-10-28 22:15:17 -04:00
README.md add: project 2 2025-10-28 22:15:17 -04:00
test.nix add: project 2 2025-10-28 22:15:17 -04:00

CS3502 Project 2: CPU Scheduling Simulation

This directory contains a simulator for various CPU scheduling algorithms.

Compilation

If you have Nix installed:

nix run .#cpu-schedulers

Otherwise, the code may be compiled using GNU Make:

make
./build/cpu-schedulers

Usage

This program supports seven scheduling algorithms:

  • sjf - Shortest Job First
  • fcfs - First Come First Serve
  • roundrobin - Round Robin
  • priority - Priority Queue
  • priorityaging - Priority Queue with Aging
  • lottery - Lottery
  • srtf - Shortest Remaining Time First

The compare option can also be entered to run all schedulers at once.

Test data must be entered by the user; all time values must be given in integers. Flags include -v for verbose debug output, and -m for machine-readable output (prints data in CSV format).