Scheduler Isolation

The didactic version of OpenEPOS implements thread scheduling (or CPU scheduling) as a property of the process management mechanisms. This is actually the way most OS implement it, but in essence, scheduling policies and mechanisms could be reused for disc, network, and other system resources. EPOS original motivation to isolate the scheduler was the possibility to implement it in hardware and thus reduce jitter for hard real-time tasks (actually threads, but that's how RT people name them)1. However, this refactoring has proven a very effective way to practice advanced software development techniques and get a insight of System-level Desgin.

To do

Before refactoring EPOS to isolate the scheduler, inspect your current implementation and answare the following questions:

  1. What are the policies implemented by the original multilevel scheduler? What is the inter-level policy? And what is the intra-level?
  2. How is it that EPOS implements a multilevel scheduler with a single Ready Queue?
  3. Could you implement other policies using the same strategy?

After answering the question, refactor the scheduler out of class Thread to create a new Scheduler class. Queues such as Ready must now be whitin Scheduler. Preserve the original polices.


1. For a deeper insight on this, please refer to the following paper: