Definition
Shortest Process Next
Shortest Process Next (SPN) selects the process with the shortest expected CPU burst time. Non-preemptive strategy that minimises average wait time in non-preemptive environments.
Properties
Selection
Process with minimum estimated execution time is chosen.
Mode
Non-preemptive — process runs until completion or blocking.
Advantages
Response Time
Significantly improves response times for short processes compared to FCFS. Optimal for minimising average wait time in non-preemptive settings.
Disadvantages
Starvation
Long processes may never run if there is a steady stream of short processes.
Estimation Difficulty
OS must estimate future CPU burst lengths, typically using exponential averaging of past bursts.
Variability
High variability in response times for long processes.
Shortest Remaining Time
SRT
Shortest Remaining Time (SRT) is the preemptive version of SPN.
- Selects process with shortest remaining execution time when new process becomes ready or current burst finishes
- Better turnaround times for short processes than SPN
- Requires tracking service time consumed by each process