Difference between Multi Level Queue Scheduling (MLQ) and Priority Scheduling
Last Updated :
16 Apr, 2025
Queue Scheduling refers to the process of managing and organizing tasks (or processes) that need to be executed by a system. In an operating system, tasks are often placed in queues waiting for CPU to execute them.
Queue scheduling helps the system decide which task to run next, and in what order, ensuring efficient and fair use of CPU.
Multi Level Queue Scheduling(MLQ)
It is quite difficult to manage all processes with just a single queue, that is where multi-level queue scheduling comes in. In this approach, processes are divided into different classes based on their characteristics, such as system processes, I/O processes, etc.
As a result, we get 'n' queues, one for each class of processes. Each queue is assigned a priority and can use its own scheduling algorithm, allowing multiple scheduling algorithms to be used simultaneously. Typically, topmost level of the queue has highest priority, and the priority decreases as you move to lower levels.
If upper levels have absolute priority over lower levels, the scheduling is non-preemptive. On the other hand, if time slices are divided between the various queues, scheduling becomes preemptive.
Priority Scheduling Algorithm
The Priority Scheduling algorithm executes processes based on their priority. Each process is assigned a priority, and the process with highest priority is executed first. Priorities can be defined both internally and externally. Internal priorities are determined by the system, based on factors such as number of resources required, the time needed, etc.
On the other hand, external priorities are based on factors like the urgency of the work, the amount paid for the task, or the importance of the process. Priority scheduling can be either preemptive or non-preemptive.
- If two processes have same priority then tie is broken using FCFS.
- The waiting time for highest priority process is always zero in preemptive mode while it may not be zero in case of non-preemptive mode.
Difference between MLQ and Priority Scheduling Algorithm
Features | Multi level queue scheduling (MLQ) | Priority scheduling |
---|
Handling | Processes are executed depending on priority of that particular level of queue to which process belongs. Further selection of process is based upon type of algorithm used in that particular queue. | It executes processes based upon their priorities i.e. in descending order of their priorities. A process with higher priority is executed first. |
Preemption | Can be preemptive or non-preemptive depending on queue algorithms. | Can be preemptive or non-preemptive depending on priority. |
Waiting Time | Average waiting time and average response time depends upon algorithms used in various levels of multi level queue for scheduling. | There is no idea of average waiting time and response time. |
Starvation | It leads to starvation of processes at lower levels of multi-level queue. | The problem of blocking of a process can be solved through aging which means to gradually increase priority of a process after a fixed interval of time by a fixed number. |
Flexibility | Offers more flexibility by allowing different queues to have different scheduling algorithms based on process type. | Less flexible, uses one scheduling method for all. |
Similar Reads
Difference between Multi Level Queue Scheduling (MLQ) and Shortest Job First 1. Multi Level Queue Scheduling (MLQ) : 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 pro
3 min read
Difference between Priority Scheduling and Round Robin (RR) CPU scheduling 1. Priority Scheduling Algorithm : Priority scheduling algorithm executes the processes depending upon their priority. Each process is allocated a priority and the process with the highest priority is executed first. Priorities can be defined internally as well as externally. Internal priorities are
3 min read
Difference between Multi Level Queue Scheduling (MLQ) and First Come First Served (FCFS) 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 scheduli
3 min read
Difference between Multi Level Queue (MLQ) Scheduling and Round Robin (RR) algorithms Queue Scheduling refers to the process of managing and organizing tasks (or processes) that need to be executed by a system. In an operating system, tasks are often placed in queues waiting for CPU to execute them. Queue scheduling helps the system decide which task to run next, and in what order, e
4 min read
Difference between Multi Level Queue Scheduling (MLQ) and Longest Job First (LJF) CPU scheduling is deciding which process or task on a computer system should be executed in the CPU at a given time. This also helps us control how many processes use the CPU at any particular period, hence optimizing the CPUâs usage. The main goal of CPU scheduling is to maximize CPU utilization an
4 min read