Skip to main content
Explain the PTE handling.
Source Link
Stephen Kitt
  • 481.4k
  • 60
  • 1.2k
  • 1.4k

Processes (or the kernel, acting on behalf of processes) pre-allocate address space, not pages. Pages come into play whenWhen a process touchesallocates memory, the corresponding addressespage-table entries are allocated, and initialised to point to the zero page (except on architectures which forbid this). When aThe zero page is first mapped inset up to a processreturn all zeroes on reads, it is zeroed outand fault on writes — the fault handler will then allocate a separate physical page.

Processes (or the kernel, acting on behalf of processes) pre-allocate address space, not pages. Pages come into play when a process touches the corresponding addresses. When a page is first mapped in to a process, it is zeroed out.

Processes (or the kernel, acting on behalf of processes) pre-allocate address space, not pages. When a process allocates memory, the corresponding page-table entries are allocated, and initialised to point to the zero page (except on architectures which forbid this). The zero page is set up to return all zeroes on reads, and fault on writes — the fault handler will then allocate a separate physical page.

Source Link
Stephen Kitt
  • 481.4k
  • 60
  • 1.2k
  • 1.4k

Processes (or the kernel, acting on behalf of processes) pre-allocate address space, not pages. Pages come into play when a process touches the corresponding addresses. When a page is first mapped in to a process, it is zeroed out.