471 views
0 votes
0 votes
Let’s take an example if I am scheduling processes in CPU using FCFS with IO Burst Time, then there will be context switching that requires hardware support. But my Teacher said Non-preemptive Algo’s don’t require hardware support.

1 Answer

1 votes
1 votes
In non-preemptive scheduling, a process runs until it either voluntarily releases the CPU or completes its execution. However, even in non-preemptive scheduling, there are scenarios where context switching may occur involuntarily due to external events, such as when a process makes a system call that requires waiting for some event to complete, like reading from a file or waiting for user input. In these cases, the process might be temporarily blocked, allowing the operating system to switch to another ready process.

This kind of preemption in non-preemptive scheduling usually occurs during system calls or other situations where a process explicitly indicates that it's waiting for an event to happen. However, the level of hardware support required for such preemption is typically less complex than what's needed for preemptive scheduling algorithms, where time slices (quantums) are strictly enforced and processes can be forcibly preempted even if they're in the middle of their execution.

Related questions

317
views
0 answers
0 votes
sripo asked Oct 24, 2018
317 views
If the mode for scheduling is not mentioned whether to do preemptive or non preemptive which one should we take when solving Gate questions?
97
views
0 answers
0 votes
Anant Mishra asked Jun 19
97 views
six jobs are waiting to be run . the expected running times are 9,7,5,2,1 and x respectively. where 5<x<7 & the average comp.time is 13. find the value of x using sjf algorithm?
232
views
1 answers
0 votes
arpit.jha asked Apr 26
232 views
Hi, All I have a question that in Process Scheduling topic most of the time we need to solve the problem using Gantt chart that's a bit time ... there any faster way to get solutions . Please provide any resource if available.Thanks
484
views
2 answers
1 votes
delxbydelt asked Mar 15
484 views
Consider a uniprocessor system with n processes in the ready queue. Round robin scheduling with time quantum x is used for process scheduling. Assume each process requires kx seconds to complete and ... nkx B) k(nx-1)C) k(nk+n)D) x(nk-n+1)