Process scheduling is a strategy that is used when there are limited resources and many processes have to compete by using them. Multi programming tries to ensure that there is some process running at all times. This is due to utilize the CPU as much as possible. when system shares time, the CPU switches so frequently between jobs that the user not feel that the machine is being shared by many processes or even many users.
If the system has more than one processor. then it is possible, then it is possible to execute more than one processor at the same time. In a single processor system, only one processor can be executed at the given time. If there are more than more processes than processors, then the operating system must schedule the processes. It means that some processes will be executed and will have to wait. There are many queues for deciding which process should be assigned the CPU.
Scheduling Queues:
There are three types of queues.
- Job Queue
- Ready Queue
- Waiting Queue
Job Queue:
Ready Queue:
The set of all processes that are in main memory and are in waiting for CPU time are kept in ready queue.
Waiting Queue:
The set of processes waiting for all allocation of certain I/O devices, are kept in waiting queue.
The set of processes waiting for all allocation of certain I/O devices, are kept in waiting queue.
No comments:
Post a Comment