in Operating System
23,024 views
10 votes
10 votes

Which of the following process scheduling algorithm may lead to starvation

 (1)SJF

(2)SRTF

(3)Priority(without preemption)

(4)Priority(with preemption)

a)1,2,3             b)1,2,4              

c)1,3,4             d)1,2,3,4    

e)1,3                f)1,4     
 

in Operating System
by
23.0k views

4 Answers

18 votes
18 votes
Best answer
All of the above algorithms can lead to starvation...

4 Comments

Can Priority Scheduling without preemption cause Starvation?
0
0
yes....
0
0
How ?
0
0
13 votes
13 votes

You should know about two things before solving this question
Indefinite Blocking (Starvation) vs Definite Blocking ..
Indefinite blocking means "we don't know how much time we should wait"
Definite blocking means "we know how much time we should wait"
So now think about the question
In all the cases we don't know how much time we should wait.
Point to recall :
FCFS Scheduling is starvation free because we know how much time we should wait(sum of burst times of all the process which came earlier)
Look at the Statement about FCFS :"Because there is no pre-emption, if a process executes for a long time, the processes in the back of the queue will have to wait for a long time before they get a chance to be executed."
This is not starvation, we are just waiting .....
Hope this will make sense....Thank you

1 comment

this answer cleared some of my myths... thank you :)
0
0
0 votes
0 votes
Option (a) is correct. As SJF- Shortest Job First case, the job which requires longer time may be starvated.

In SRTF -Shortest Response Time first - In this case also the jobs with higher response time will be starvated.

Similarly with no preemption the jobs are likely starvated.

hnce the option (a) is correct.
0 votes
0 votes

According to me the answer should be option 2 and 4 as they are premptive algorithms. There is difference between waiting and starvation. Hence option 1 and 3 lead to waits and option 2 and 4 leads to starvation. 

Answer:

Related questions

0 votes
0 votes
1 answer
4