before we learn what is process scheduling we will first understand what is process
PROCESS:A process is the instance of a computer program that is being executed by one or many threads.
PROCESS SCHEDULING:
- consider CPU contains a process which is currently being executed, while it is being exected it may require input from the user or a call to subroutine in that cases the CPU has to sit idle till the process continues its execution again this time will be wated insted till that time another process can be executed by the CPU.
- this method of assigning the process to the CPU is called as process scheduling
- this is done by using certain statergies like FIFO, priority , round robin fashion etc.
PROCESS SCHEDULING QUEUES:The OS maintains a separate queue for each of the process states and PCBs of all processes in the same execution state are placed in the same queue.
-
Job queue − This queue keeps all the processes in the system.
-
Ready queue − This queue keeps a set of all processes residing in main memory, ready and waiting to execute. A new process is always put in this queue.
-
Device queues − The processes which are blocked due to unavailability of an I/O device constitute this queue.