in Operating System
6,911 views
1 vote
1 vote
Q1) _________________ scheduler hold the degree of multi programming

Q2) _________________ scheduler reduces the degree of multi-programming.
in Operating System
by
6.9k views

1 comment

@Habibkhan @Arjun @srestha I have a doubt , does mid term scheduler control degree of multiprogramming?

0
0

2 Answers

15 votes
15 votes
Best answer

a) The long term scheduler actually controls or we can say holds the degree of multiprogramming .It is the responsibility to bring CPU bound process and I/O bound process in the ready state and hence in main memory in an appropriate ratio.CPU bound processes are those processes which consume most of the time in CPU so CPU time is larger than I/O time whereas I/O bound processes consume less CPU time and more I/O time.

So more number of CPU bound processes means the I/O wait state will remain idle similarly if we have more I/O bound processes then CPU will remain idle and hence throughput will decrease.So it is the responsibility of long term scheduler to bring CPU bound and I/O process to the ready state in the balanced ratio.

b) The task of decreasing the degree of multiprogramming i.e. no of process in main memory is done by mid term scheduler which is also known as "swapping out" of the process.It is quite possible that the no of processes created by LTS and submitted to the ready state may be high.In that case , LTS cannot take back the process.So here comes the role of mid term scheduler.It swaps out the process from main memory to secondary memory(from ready state to suspend ready state) , thereby reducing the degree of multiprogramming.Similarly a process may also be suspended in I/O wait state by MTS if adequate resources are not available.

So answer to a) part should be long term scheduler and part b) should be mid term scheduler.

selected by

4 Comments

That's why I have said that long term scheduler holds or in other words , controls the degree of multiprogramming.According to situation , it may increase or decrease the degree of multiprogramming.So we cannot say that LTS is responsible for decrease mainly.If a situation arises where there are more number of processes , then it is MTS which decreases  the degree of multiprogramming by swapping out of the main memory to secondary memory.
1
1
ohk thanks;
0
0

@Habibkhan

Q1>I have  a question that suppose the long term scheduler gives only CPU bound  processes does it have any effect on the degree of multiprogramming?

 

Q2>If it gives only IO bound processes will it have any effect  on the multiprogramming?

 

2
2
0 votes
0 votes
I think both are long term scheduler.. holding I am assuming is controlling d degree of multi programming