You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I just read chapter 2 and I really like the article so far.
I wanted to add a bit of clarification regarding the coop multitasking:
Rather than the OS deciding when to preempt programs, the programs themselves would choose to yield to the OS. They would trigger a software interrupt to say, “hey, you can let another program run now.” These explicit yields were the only way for the OS to regain control and switch to the next scheduled process.
The OS would use any system call to check if the process has consumed its time slice and to switch to another process. The yield system call was there for the case, where your program doesn't need to make system calls (e.g. it's doing some number crunching and all the data it needs is in memory already), but you still want to be a good citizen and to give the other processes a chance to run.
The text was updated successfully, but these errors were encountered:
I just read chapter 2 and I really like the article so far.
I wanted to add a bit of clarification regarding the coop multitasking:
The OS would use any system call to check if the process has consumed its time slice and to switch to another process. The yield system call was there for the case, where your program doesn't need to make system calls (e.g. it's doing some number crunching and all the data it needs is in memory already), but you still want to be a good citizen and to give the other processes a chance to run.
The text was updated successfully, but these errors were encountered: