Docsity
Docsity

Prepare for your exams
Prepare for your exams

Study with the several resources on Docsity


Earn points to download
Earn points to download

Earn points by helping other students or get them with a premium plan


Guidelines and tips
Guidelines and tips

CPU Scheduling Assignment 5 - Concepts of Computer Science | CS 111, Assignments of Computer Science

Material Type: Assignment; Class: Concepts of Computer Science; Subject: Computer Science; University: Southern Illinois University Edwardsville; Term: Spring 2008;

Typology: Assignments

Pre 2010

Uploaded on 08/16/2009

koofers-user-63e
koofers-user-63e 🇺🇸

10 documents

1 / 2

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
CS 111.002: CONCEPTS OF COMPUTER SCIENCE
SPRING 2008
HOMEWORK #5: CPU SCHEDULING
DUE DATE: WEDNESDAY, MARCH 26, 2008 AT 2:00 PM
NAME: ______________________________________
A CPU finishes processing a job, only to find that six new jobs have arrived, ready to be
processed:
Job:
Order of Arrival:
1
2
3
4
5
6
Time to Process
(in microseconds):
750
2000
500
4500
250
1000
Priority:
High
Medium
Low
High
Medium
Low
If the operating system utilizes a first-come-first-served CPU scheduling strategy, then the
jobs will each finish according to the following timetable:
Job:
Total Time to Finish
(in microseconds):
750
3250
7750
9000
This yields an average completion time of (750 + 2750 + 3250 + 7750 + 8000 + 9000)/6 =
5250 microseconds. Since these jobs have an average processing time of 1500 microse-
conds, there is a 250% average delay factor (i.e., (5250-1500)/1500).
1. (2 points) Fill in the individual completion times, the average completion time, and the
average delay factor for these jobs if the operating system utilizes a shortest-job-first
CPU scheduling strategy.
Job:
Total Time to Finish
(in microseconds):
Average Completion Time: __________ microseconds
Average Delay Factor: __________ %
pf2

Partial preview of the text

Download CPU Scheduling Assignment 5 - Concepts of Computer Science | CS 111 and more Assignments Computer Science in PDF only on Docsity!

CS 111.002: CONCEPTS OF COMPUTER SCIENCE

SPRING 2008

HOMEWORK #5: CPU SCHEDULING

DUE DATE: WEDNESDAY, MARCH 26, 2008 AT 2:00 PM

NAME: ______________________________________

A CPU finishes processing a job, only to find that six new jobs have arrived, ready to be processed:

Job:      

Order of Arrival: 1 2 3 4 5 6

Time to Process (in microseconds):

Priority: High Medium Low High Medium Low

If the operating system utilizes a first-come-first-served CPU scheduling strategy, then the jobs will each finish according to the following timetable:

Job: (^)      

Total Time to Finish (in microseconds):

This yields an average completion time of (750 + 2750 + 3250 + 7750 + 8000 + 9000)/6 = 5250 microseconds. Since these jobs have an average processing time of 1500 microse- conds, there is a 250% average delay factor (i.e., (5250-1500)/1500).

  1. (2 points) Fill in the individual completion times, the average completion time, and the average delay factor for these jobs if the operating system utilizes a shortest-job-first CPU scheduling strategy.

Job:      

Total Time to Finish (in microseconds):

Average Completion Time: __________ microseconds

Average Delay Factor: __________ %

  1. (3 points) Fill in the individual completion times, the average completion time, and the average delay factor for these jobs if the operating system utilizes a round-robin CPU scheduling strategy (with 250-microsecond time slices for every job). Assume that the round-robin follows the order of arrival of the jobs.

Job:      

Total Time to Finish (in microseconds):

Average Completion Time: __________ microseconds

Average Delay Factor: __________ %

  1. (5 points) Fill in the individual completion times, the average completion time, and the average delay factor for these jobs if the operating system utilizes a multilevel- feedback-queue CPU scheduling strategy (using 750-microsecond time slices for every job on the high priority queue, 250-microsecond time slices for every job on the me- dium priority queue, and 100-microsecond time slices for every job on the low priority queue). Assume that the round-robin on each queue follows the order of arrival of the jobs.

Job:      

Total Time to Finish (in microseconds):

Average Completion Time: __________ microseconds

Average Delay Factor: __________ %