A simulator for several algorithms which are used by operating system CPU schedulers. Includes simulations of FCFS, SRTF, and Round-robin.
Make sure you are using an environment with a recent version of GCC installed.
- Enter the project directory
- Run
make
- Run the program with
./schedule <input filename>
. You can use the includedin.txt
file as an example
The program expects an input file in plaintext with the following format:
- One process definition per line
- Two integers per process definition line, separated by a space
- The first integer is the processes' arrival time (in terms of "ticks")
- The second integer is the amount of CPU time the process needs (also in terms of "ticks")
You can see an example of acceptable formatting in the file in.txt
within the project root.