How is cpu's state saved by os without altering it?

24 Views Asked by At

During the context switch the operating system (OS) needs information from the CPU to create a Process Control Block (PCB), but accessing the CPU could alter the very information it's trying to capture. please tell me how this is handled.

I have read books on operating system but none of them go into it as i recall. I am unable to find any answer on the web too.

0

There are 0 best solutions below