Less used for job scheduling, more used for process scheduling. Shortest Remaining Time First ( SRTF ) or preemptive sjf cpu scheduling in java On-campus and online computer science courses to Learn the basic concepts of Computer Science. # include # include typedef struct PCB Īdvantages: to ensure that new short jobs can be served quickly as soon as they enter the system, and the average waiting time is short.ĭisadvantages: In order to ensure the process breakpoint is live, counting the remaining time of the process increases the system overhead, which is not conducive to long operations. Realization idea: When a new process enters the ready queue, if it needs processing time shorter than the processing time of the current process, the current process is suspended and the CPU is allocated to the new process.
0 Comments
Leave a Reply. |