From the user space, you can define a signal handler for SIGSEGV, so your own function will be called whenever an invalid memory access is made. Combined with mprotect()this, it allows the program to manage its own virtual memory, all from user space.
, (, ) . , . , do_page_fault(). , . , - (.. ).