Quantcast
Channel: Active questions tagged operating-system+scheduling - Stack Overflow
Viewing all articles
Browse latest Browse all 211

What does having positive/negative ready_rate and running_rate do?

$
0
0

I would like to check if my answer is correct for the following question:

I am asked:Give a discussion about how scheduling works in each of the following two cases:

  1. Both parameters running rate and ready rate are positive.
  2. Both parameters running rate and ready rate are negative.

where:

In the ready state, the priority of a process changes according to the quadratic function

priority(t) = priority(t0) + ready rate × (t − t0)²

, where t is the current time and t0 is the time of its arrival at the ready queue.

In the running state, the priority of a process changes over time according to the quadraticfunction

priority(t) = priority(t0') + running rate × (t − t0')²

, where t is the current time and t0' is the time it starts running.

My answer:

If both parameters are positive then there is a increased probability that that a higher priority process in the system gets scheduled. It will continue to be processed until another higher priority process comes in or its burst time is finished.In this case It is not necessarily the case that all high priority process will preempt a running low priority process. This is because running rate is higher than ready rate In this case a lower priority process will never cause a running high priority process to be preempted.

If both running rate and ready rate are negative then there is a higher probability that an incoming lower priority process to be preempt a higher priority process. The reason for this is that running rate is higher than ready rate


Viewing all articles
Browse latest Browse all 211

Latest Images

Trending Articles



Latest Images

<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>