Lab 2: Scheduler

Handed out Tuesday Feb. 2, 2020
Due Monday Feb. 22, 2020

Implement priority scheduling

In this assignment, you will change the scheduler from a simple round-robin to a priority scheduler. Add a priority value to each process (lets say taking a range between 1 to 16). The range does not matter, it is just a proof of concept. When scheduling from the ready list you will always schedule the highest priority thread/process first.

Add a system call to change the priority of a process. A process can change its priority at any time. If the priority becomes lower than any process on the ready list, you must switch to that process.

To get started, look at the file proc.c Implement one of the next four items. If you implement more, each is a 5% bonus. To get credit for a bonus part, you must also develop a user test that will illustrate it. Note that lab bonuses only count towards lab scores.

Goals: Understand how the scheduler works. Understand how to implement a scheduling policy and characterize its impact on performance. Understand priority inversion and a possible solution for it.