4 ms·
Well I was going to say that if you were only concerned with stopping execution, you could just count the number of instructions executed but alas TFA mentions
by andreareina 7y ago
Well I was going to say that if you were only concerned with stopping execution, you could just count the number of instructions executed but alas TFA mentions that already. I'm not familiar with modern schedulers but it seems to me that to continue execution from a stopping point you'd need to restore (and therefore save) at least the instruction and stack pointers, plus maybe a couple other pointers for stuff like the global and current environments. Obviously if you're operating a register machine you'd need to stash/restore the state of all the registers as well, IIRC x86 uses the stack for that.