+ All Categories
Home > Documents > 2 v1.20. contents copyright 2014 Mark Minasi. Copying this without permission is really, really...

2 v1.20. contents copyright 2014 Mark Minasi. Copying this without permission is really, really...

Date post: 08-Jan-2018
Category:
Upload: elvin-parker
View: 227 times
Download: 0 times
Share this document with a friend

If you can't read please download the document

Transcript

2 v1.20. contents copyright 2014 Mark Minasi. Copying this without permission is really, really rude.. Let's say that Process "A" needs the CPU to wake up every 10 ms, and so creates a trigger that "fires" every 10 ms. Suppose the wake-up time is 3 ms after the trigger fires, and the time to do whatever A needs takes another 1 ms, like this: Wake 3 ms 6 ms nothing, CPU goes back to sleep A 1 ms Do whatever A needs done A Wake A A A If we do several cycles, then, it looks like Result: the CPU sleeps about 60% of the time. Nice, from a battery drain point of view. Time A Wake A A A Now let's add a second process, B, that also fires every 10 ms. As before, the OS needs 3 ms to wake up the CPU, and let's say that B's service time is also just 1 ms per fire but it started later, unknowing of and out of phase with A: B Wake B B B Result: now the CPU only sleeps 20% of the time. Can we do better? A Wake A A A This is nuts we're wasting the CPU's time with unnecessary wake-ups. Wake B B BB Now the CPU sleeps 50% of the time! Answer: the OS forces A and B's timers to fire at the same time, burning less CPU time and less battery Part of how Windows Store apps are built to be safer is by greatly reducing their access to the rest of the system; you see that in a new SID S or "ALL APPLICATION PACKAGES" as in this screen shot of the DACLs for the Windows folder Also


Recommended