![]() |
VOOZH | about |
Processes are scheduled using a variety of algorithms in CPU scheduling. First come first serve (FCFS), Shortest Job First (SJF), Shortest Remaining Time First (SRTF), Priority Scheduling, Round Robin (RR), Multi-Level Queue (MLQ), and Multi-Level Feedback Queue (MLFQ) are just a few of the scheduling algorithms available.
These scheduling algorithms are used to handle operating system scheduling, which is in charge of assigning CPU time to available processes. To increase user interaction, throughput, and real-time response, among other things.
It is quite difficult to have just one queue and schedule all the processes. This is where multi level queue scheduling is used. In this the processes are divided into various classes depending upon the property of the processes such as system process, I/O process etc.
Multilevel Queue Scheduling is a CPU scheduling mechanism where the process is divided into several hierarchy queues and each queue possesses a different priority, and process type. The scheduling algorithm can be different for each Queue and these processes are mapped in a permanent manner to a particular Queue following some criteria, for example in relation to priority or resources.
First Come First Served (FCFS) is the simplest CPU scheduling algorithm, where processes are executed in the order they arrive. It uses a queue data structure to manage the ready queue.
The process at the front of the queue is allocated the CPU, and execution begins. A new process entering the system is added to the end of the queue. Each process runs to completion before the next one starts.
| Feature | FCFS (First Come First Served) | MLQ (Multilevel Queue) |
|---|---|---|
| Preemption | Non-preemptive | Can be preemptive or non-preemptive |
| Execution Order | Processes executed in arrival order | Based on queue priority; each queue may use different algorithms |
| Overhead | Minimal | Higher due to context switching between queues |
| Response Time | High, especially for long processes (convoy effect) | Varies based on queue and scheduling policies |
| Waiting Time | Generally high | Depends on queue priorities and scheduling algorithms |
| Time-Sharing Systems | Not suitable | Well-suited for time-sharing |
| Complexity | Simple to design and implement | More complex due to multiple queues and possible preemption |
| Drawbacks | Convoy effect; poor performance in interactive systems | Starvation of lower-priority queues; higher overhead |
| Implementation | Easy | More difficult due to need for managing multiple queues |