Question

In a single CPU single core system, schedule the following jobs to take the full advantage...

In a single CPU single core system, schedule the following jobs to take the full advantage of multiprogramming. The following table shows how the jobs would look like if they ran in isolation.

JOB1

JOB2

JOB3

Type of job

Full CPU

Only I/O

Only I/O

Duration

5 min

15 min

10 min

Memory required

50MB

100MB

75MB

Needs disk?

No

No

Yes

Needs terminal?

No

Yes

No

a) Fill out the multiprogramming column in the following table (i.e., when the jobs are scheduled in multiprogramming). Assume that the system’s physical memory is 256MB.

Average Resource Use

Sequential

Multiprogramming

Processor

5/30 = 16.67%

Memory

32.55%

Disk

33.33%

Terminal

50%

Memory usage is computed as follows: (5minx50MB + 15minx100MB + 10minx75MB) / (30minx256MB) = 32.55%

Other resources are fully utilized during the time they are utilized. So, you compute utilization only based on the duration they are used.

b) What is the total time for completion for all jobs in sequential and multiprogrammed model?

Homework Answers

Answer #1

(a) The resources used are CPU, memory, disk and Terminal. Note that Job1 requires only CPU and memory (50 MB), Job2 requires only Terminal and memory (100 MB), and Job3 requires only Disk and memory (75 MB). In multiprogrammed model, all the programs are run at the same time. Thus, the total running time of the program is the running time of the longest job.

Longest job is Job2 (15 mins). So running time in multiprogrammed model is 15 minutes.

Average Processor Use = 5/15 = 33.33 %

Average Memory Use = (5x50 + 15x100 + 10x75) / (15x256) = 65.1 %

Average Disk Use = (10 min) / (15 min) = 66.67 %

Average Terminal Use = (15 min) / (15 min) = 100 %

(b) In sequential model, programs are run one after the other. Thus, total completion time for all the jobs is the sum of the running times of all the jobs. In multiprogrammed model, running time is the time required by the longest job.

Sequential completion time = 5 + 15 + 10 = 30 minutes

Multiprogrammed completion time = max(5, 15, 10) = 15 minutes

Know the answer?
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for?
Ask your own homework help question
Similar Questions
ADVERTISEMENT
Need Online Homework Help?

Get Answers For Free
Most questions answered within 1 hours.

Ask a Question
ADVERTISEMENT