Young heart be free tonight, TIME is on your side!
Thanks much Rod, that's an awesome song!
What is time? And why it is so important specially in computing?
It is important, just because lot of computing resources are being shared between contending customers. Here the customers are mainly applications, and in this sense operating systems are also customers. And the only canonical measure of sharing or in general for everything else in life is Time. Yeah, we all know the New yourker joke "What Time is it? - That's none of your business."
So for sharing resources by time, there has to be a controller and in our case it is the OS that needs of have the control of the processing and decide who gets what resources, but mostly the CPU time is what it is concerned of. And in order to get the control, the hardware has to assert interrupt every once in a while. That is the key design issue. If the hardware does that more frequently, it would be interrupt storm, and if it does less frequently the sharing is not very granular, hence average waiting time to get hold of CPU would increase.
How often the hardware interrupt for time slice is a reasonable question. In lot of cases it is every 10 millisecond. So for the timer processing the OS would get control thru timer ISR every 10 or so milliseconds.
Now the questions like the following must come to your mind, if you want to get just a tad bit deeper -
1) What if I want to have a synchronous delay that is less than 10 ms?
2) What if the timer processing takes a significant part of the the 10 ms epoch?
3) etc., etc.
For question number (1), you can always refer to the linux implementation of BogoMIPS ( i.e Bogus Mips ) and how it derives micorsecond or nano second delay. For (2), the ISR processing should be alpha * epoch, where epoch equals 10ms in our case and alpha is defined to be 0 < alpha < 1. If alpha is 1/2 then half the time goes just to process the interrupt service. This gives us a clue that if the processor speed grows exponentially, we might even see 5ms timer interrupts or even less...
Well that's 'bout it - now let me go to YouTube to listen one more time - Young heart be free tonight, TIME is on your side.
References (2)
-
Response: essay writing servicesThe young time can be presented on the successful ways. They have gotten one on the same success. They have easy to predate on the waited project. These are the main causes of the same success in our life.
-
Response: best drone camera under 100
Reader Comments