5 questions to test your understanding
A page fault occurs when the CPU tries to execute an instruction at virtual address X. After the OS handler loads the missing page from disk, execution resumes at...
A user program executes the 'syscall' instruction to request kernel services. What type of exception is this, and where does execution resume after the handler returns?
Exception handlers can run in user mode if the faulting process has sufficient privileges, allowing fast, OS-bypass handling.
A fault saves the instruction pointer to the address of the faulting instruction so that, after the handler resolves the problem, the same instruction can be retried.
What is the difference between a fault and a trap in terms of the saved return address, and why does this distinction matter for the correct behavior of virtual memory?