Convoy effect : SJF

  • 0

    We know that FCFS suffers from the convoy effect but Question : Does SJF (Shortest Job First) suffer from the convoy effect and if yes then how ?

  • 4

    There are 2 version of SJF

    1. Shortest Job first (SJF) which is Non preemptive mode , This will suffer from convoy effect as if the very first process which came is Ready state is having a large burst time . So it will be scheduled on CPU as it is the only process. Then soon after other processes came which have small burst time but 1st process will keep on executing as SJF is Non Preemptive Mode. This will affect the Avg. waiting time of the processes which will led to Convoy Effect.

    2. Shortest Remaining Time First Preemptive version of SJF. This will never suffer from Convoy effect.

  • 0


    explanation : criteria in SJF is (arrival time + burst time) , so a job with shorter burst time wont arrive then we cant take it and in this case if it is non preemptive then SJF will also suffer from the convoy effect , you can take an example and check it

  • 0

    Can we claim that any non-preemptive scheduling algorithm suffer from convoy effect?

Log in to reply

Looks like your connection to LeetCode Discuss was lost, please wait while we try to reconnect.