Question: NEED HELP PLEASE NEED ASAP!!!!!!!!!!!!!!!! A system adopts a priority-based preemptive scheduling where the initial priority of a process increases by 1 after every 5ms.

NEED HELP PLEASE

NEED ASAP!!!!!!!!!!!!!!!!

  1. A system adopts a priority-based preemptive scheduling where the initial priority of a process increases by 1 after every 5ms. In a recorded time span, the system has four processes P1, P2, P3, P4 as shown in the following table: (10 points)

Process ID

Initial Priority

Arrival Time in ms

Total CPU time in ms

P1

1

0

15

P2

3

5

7.5

P3

2

10

5

P4

2

15

10

Draw a timing diagram similar to Fig 3.7 and find the turnaround time for each process. Assume that the dispatcher takes 2.5ms for a process switch.

NEED HELP PLEASE NEED ASAP!!!!!!!!!!!!!!!! A system adopts a priority-based preemptive scheduling

  1. Write a multithreaded program that calculates various statistical values for a list of numbers. This program will be passed a series of numbers on the command line and will then create three separate worker threads. One thread will determine the average of the numbers, the second will determine the maximum value, and the third will determine the minimum value. For example, suppose your program is passed the integers
    1. 90 81 78 95 79 72 85

The program will report

The average value is 82

The minimum value is 72

The maximum value is 95

The variables representing the average, minimum, and maximum values will be stored globally. The worker thread will set these values, and the parent thread will output the values once the workers have exited. (30 points)

Process A Process B Process C . Dispatcher 0 5 10 15 20 25 30 35 40 45 50 =Ruing = Ready = Blocked Figure 3.7 Process States for Trace of Figure 3.4

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!