in Operating System
1,787 views
1 vote
1 vote
A soft real-time system has four periodic events with periods of $50, 100, 200,$ and $250$ msec each. Suppose that the four events require $35, 20, 10,$ and $x$ msec of CPU time, respectively. What is the largest value of $x$ for which the system is schedulable?
in Operating System
1.8k views

2 Answers

2 votes
2 votes

Answer:

We require $\frac{35}{ 50} + \frac{20}{ 100} + \frac{10}{ 200} +\frac{\mathrm x}{ 250} ≤ 1$

So, the largest possible value of $\mathrm x = 0.7 + 0.2 + 0.005 + \frac{\mathrm x}{250} = 1 \\ \;\;\Rightarrow \mathrm x = 12.5 $

Thus the largest possible x satisfying $ 0.7 + 0.2 + 0.05 + \frac{\mathrm x}{250} = 1$

 $ \qquad \qquad \qquad \qquad\qquad\qquad \Rightarrow \mathrm x = 12.5$

$\therefore $The answer is $\mathrm x = 12.5$

edited by
by

2 Comments

Why to take <=1....what's the concept behind that
0
0
We have to achieve the cpu time divided by the sum of period equal to 1.

It can never be greater than 1.

In the best case it can be 1.
0
0
1 vote
1 vote
yes the best utilisation of CPU will be 1.

In this case (35/50)+(20/100)+(10/200)+(x/250) should be equal to 1 in best case.

Hence (35/50)+(20/100)+(10/200)+(x/250)=1 which gives x=12.5 ms

Related questions