Computer Operating System learning notes _ 4 _ Process Management-Processor Scheduling

Source: Internet
Author: User
Process Management-Processor Scheduling



I. Basic concepts of scheduling

1. Job Scheduling

Job Scheduling is also calledMacro or Advanced scheduling. Select a job in the backup status and create a process. Generally, most batch processing systems are equipped with job scheduling. In other systems, Job Scheduling is usually not required. The Job Scheduling frequency is low, usually several minutes.

2. Process Scheduling

Process Scheduling is an operation that determines which process in the ready queue will obtain the processor and actually allocate the processor to the process.

3. Exchange Scheduling

Exchange scheduling is also calledIntermediate Scheduling. The main task is to transfer the ready processes in the external memory swap Zone according to the given principles and policies to the memory, or switch the process in the memory ready state or memory blocking state to the external memory swap area.


Ii. Scheduling time, switching and Process

1. Events that cause Process Scheduling

The running process is completed or an event occurs.Cannot continue running;

Running ProcessInput/Paused upon output request;

Some primitive operations, such as P operations, are run during process communication or synchronization;

 In preemptive SchedulingA process with a higher priority than the current process enters the ready queue;

In the time slice rotation method, the time slice is used up.



2. Scheduling queue

In a single-processor system, only one process is running.



3. Dispatcher)

Process Scheduling AlgorithmIt is a policy to determine which process will obtain the processor.Setter, AndThe specific operations for assigning a processor to the process are completed by the dispatcher.. The allocation program is a mechanism,Actual OperatorTherefore, its operation efficiency is high. This fully embodies the design philosophy of policy and mechanism separation.



III. Basic scheduling principles

The basic scheduling principles include:

Processor utilization: Try to keep expensive processors busy.

Throughput: the maximum number of processes completed per unit time.

Turnaround time: the time taken from job submission to job completion. Make the turnaround time as small as possible.


Backup time: it refers to the time when the job arrives at the system and waits for memory to enter in the external storage. The smaller the time, the better.

Waiting Time: refers to the time in the ready queue waiting for scheduling to enter the processor.

Response time: the time from request submission to First Response output.



Iv. scheduling mode

1. scheduling methods include:

Not preemptive

Preemptive Mode



2. process scheduling algorithm comparison

(1) first-come first-served (FCFS ).

(2) Short jobs or short processes (threads) are given priority (SJF & SPF ).

(3) high response ratio Priority Scheduling (hrrn) algorithm.

Response RatioRp = (Wait time+Estimated running time)/Estimated running time=Turnaround time/Estimated running time

(4) Scheduling Algorithm with high priority.

Static Priority and dynamic priority.

(5) time slice rotation scheduling algorithm (RR ).

(6) Multi-Level feedback queue scheduling algorithm. (Advantages of the first several algorithms of the Collection class)



Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.