






Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
Prepare for your exams
Study with the several resources on Docsity
Earn points to download
Earn points by helping other students or get them with a premium plan
Various problems with multilevel queue scheduling in operating systems, including the potential for low priority threads to starve and the inability to accurately predict future cpu requirements. It also explores solutions such as fifo, rr, stcf, multi-level feedback, and lottery scheduling. The document also touches upon unix scheduling problems and the implementation of linux scheduling classes.
Typology: Slides
1 / 12
This page cannot be seen from the preview
Don't miss anything!







Can’t low priority threads starve?
What about when past doesn’t predict future?
How does the priority scheme scale with number of processes?
How to give a process a given percentage of CPU?
OS implementation problem:
Builds on traditional UNIX multi-level feedback queue scheduler by adding two new scheduling classes.
Linux scheduling classes:
Multiple priorities may be used within a class
Priorities in real-time classes are higher than non-real-
time classes.
SCHED_RR class is similar to SCHED_FIFO except that there is a time-slice associated with an RR thread. On expiry of the time slice, if the thread is still executing, it is pre-empted and another thread from either SCHED_FIFO or SCHED_RR is selected for execution.
SCHED_OTHER class is managed by the traditional UNIX scheduling algorithms i.e. multi-level feedback queue.
Problem: this whole priority thing is really ad hoc.
How to ensure that processes will be equally penalized under load?
Lottery scheduling! Very simple idea:
give each process some number of lottery tickets On each scheduling event, randomly pick ticket run winning process to give process P n% of CPU, give it (total tickets)* n%
How to use?
Approximate priority: low-priority, give few tickets, high-priority give many Approximate STCF: give short jobs more tickets, long jobs fewer. Key: If job has at least 1, will not starve
Classifications of Multiprocessor
Systems
Loosely coupled or distributed multiprocessor, or
cluster
Functionally specialized processors
Tightly coupled multiprocessing
Granularity of parallelism
Coarse and Very Coarse-Grained Parallelism