Question

In: Computer Science

Assume you have the following jobs to execute with one processor, with the jobs arriving in the order listed above.

i t(pi)
0 80
1 20
2 10
3 20
4 50
  1. Assume you have the following jobs to execute with one processor, with the jobs arriving in the order listed above.
  2. Suppose a system uses FCFS scheduling. Create a Gantt chart illustrating the execution of these processes . b   What is the turnaround time for process p3? c.   What is the average wait time for the processes?

Using the process load above, suppose a system uses SJN scheduling.

d Create a Gantt chart illustrating the execution of these processes.
e.   What is the turnaround time for process p0?
f What is the average wait time for the processes?

Solutions

Expert Solution

Waiting Time = Start Time - Arrival Time

Turn Around Time = Completion Time - Arrival Time

Average Waiting Time = Sum of waiting time of all processes / Number of processes

FCFS Scheduling:

SJN Scheduling:

 


Related Solutions

Assume you have the following jobs to execute with one processor: i t(pi) Priority 0 80...
Assume you have the following jobs to execute with one processor: i t(pi) Priority 0 80 2 1 25 4 2 15 3 3 20 4 4 45 1 The jobs are assumed to arrive at the same time. Using priority scheduling followed by FCFS, do the following: Create a Gantt chart illustrating the execution of these processes. What is the turnaround time for process p1? What is the average wait time for the processes?
Assume you have the following jobs to execute with one processor: i t(pi) Arrival Time 0...
Assume you have the following jobs to execute with one processor: i t(pi) Arrival Time 0 75 0 1 40 10 2 25 10 3 20 80 4 45 85 Using the table, assume the context switch time is five time units with RR scheduling. Create a Gantt chart illustrating the execution of these processes. What is the turnaround time for process p3? What is the average wait time for the processes?
Assume, you are trying to execute the following jobs with execution times and their varying arrival...
Assume, you are trying to execute the following jobs with execution times and their varying arrival times are given. These jobs are run on a single processor using pre-emptive SJF algorithm. If the average waiting time of the processes is 4 millisecond, then the value of X is________. Show the equation with values that helps you to find the value of X. Process No: J1 J2 J3 J4 J5 J6 Arrival time: 0 1 2 3 4 5 Burst Time:...
The jobs listed below need to be completed. Assume that it is now day 140. If...
The jobs listed below need to be completed. Assume that it is now day 140. If the jobs are sequenced according to the shortest processing time rule and earliest due date rule, a. what is the job processing sequence for each rule? b. what is the average flow time for each rule? c. what is the utilization for each rule? d. what is the average job lateness for each rule? e. what is the average number of jobs in a...
All the situations listed below needs the use of accounting information to execute one or more...
All the situations listed below needs the use of accounting information to execute one or more of the following managerial tasks: (1) planning, (2) control and evaluation, (3) continuous improvement, or (4) decision making. MANAGER: At the previous executive board meeting, we built up a target of procuring an after-tax profit equivalent to 25 percent of sales. I would like know the total revenue that we have to make so as to meet this goal, given that we have RM350,000...
Google provide a brief overview of the successful company listed above, that you have chosen to...
Google provide a brief overview of the successful company listed above, that you have chosen to benchmark for management best practices. You should also include specific examples relating to the fundamental principles of management and the company's mission and vision statement.
Explain a scenario for observational learning in order to have an organism execute a desired behavior...
Explain a scenario for observational learning in order to have an organism execute a desired behavior by answering the following questions. (Please be specific and detailed in your answers and write in full sentences.) What is the desired behavior and the person and/or animal chosen for this scenario? Why did you choose this behavior? Is this behavior prosocial or antisocial? How will confirm that the observer is focused on what the model is doing? How will you confirm that the...
Assume that you have a set of jobs where each has only a processing time that...
Assume that you have a set of jobs where each has only a processing time that you need to schedule on a single machine. Explain how you should schedule the jobs to minimize the sum of completion (finish) times. Write a proof that your schedule is optimal.
Assume you have a superscalar CPU with in-order issue and in-order instructions that uses 8 registers...
Assume you have a superscalar CPU with in-order issue and in-order instructions that uses 8 registers (R0-R7). The usual rules include: up to two instructions can be issued in one cycle; instructions have to complete in the order they are issued; an instruction attempting to write to a register that is being read by any incomplete instruction cannot be issued until the incomplete instruction completes; any instruction attempting to read a register that is being written to by any incomplete...
4.16 Inthisexercise,weexaminehowpipeliningaffectstheclockcycletimeofthe processor. Problems in this exercise assume that individual stages of the datapath have the...
4.16 Inthisexercise,weexaminehowpipeliningaffectstheclockcycletimeofthe processor. Problems in this exercise assume that individual stages of the datapath have the following latencies: 250ps 350ps 150ps 300ps 200ps Also, assume that instructions executed by the processor are broken down as follows: 45% 20% 20% 15% 4.16.1 [5] <§4.5> What is the clock cycle time in a pipelined and non-pipelined processor? 4.16.2 [10]<§4.5>WhatisthetotallatencyofanLDURinstructioninapipelined and non-pipelined processor? 4.16.3 [10] <§4.5> If we can split one stage of the pipelined datapath into two new stages, each with half...
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT