1 / 12

Process Scheduling ( 5.1-5.3)

Learn about CPU-bound and I/O-bound processes, scheduling criteria, algorithms like FCFS and SJF, and prediction methods for CPU burst times. Explore different scheduling modes and circumstances in operating systems.

rubenstein
Download Presentation

Process Scheduling ( 5.1-5.3)

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Process Scheduling(5.1-5.3) Nov 16, 2007 CPE 261403 - Operating Systems http://groups.google.com/group/cpe-os cpe-os@googlegroups.com

  2. The Assumption that Makes Multiprogramming Work • CPU-Bound Process • I/O-Bound Process Figure 5.1

  3. Process Scheduling Figure 3.6

  4. Scheduling Circumstances (5.1.3) 5 2 4 1 3 Figure 3.2

  5. Scheduling Modes • Nonpreemptive (Cooperative) • Windows 3.x • MacOS ( v.9 and earlier) • Preemptive • Windows 95 and later • MacOS X

  6. Scheduling Criteria (5.2) • CPU Utilization • Throughput • Turnaround time • Waiting time • Response time

  7. Scheduling Algorithms (5.3)

  8. P1 P2 P3 0 24 27 30 First-Come, First-Serve (FCFS) ProcessBurst Time P1 24 P2 3 P3 3 • Waiting time for P1 = 0; P2 = 24; P3 = 27 • Average waiting time: (0 + 24 + 27)/3 = 17

  9. P2 P3 P1 0 3 6 30 First-Come, First-Serve (FCFS) • P2, P3, P1 Waiting time for P1 = 6; P2 = 0; P3 = 3 Average waiting time: (6 + 0 + 3)/3 = 3

  10. Shortest-Job-First Scheduling (SJF) • SJF is optimal – gives minimum average waiting time • Two schemes: • Nonpreemptive • Preemptive (shortest-remaining-time-first)

  11. Predicting CPU Burst Time Exponential Average

  12. Prediction Example Actual Prediction Figure 5.3

More Related