0:00
/
Preview

Page Tables from First Principles

Constructing page tables from first principle as a way to store virtual-to-physical address mappings

This is the fourth video in our virtual memory series based on the article/ebook I wrote. In the last few videos, we covered what virtual memory is, its size, and the address space layout of a process. In this video, we learn how the kernel stores virtual-to-physical address mappings in the form of a page table, what that looks like, and how the hardware performs an address translation by walking the page table.

But instead of jumping directly to page tables, we derive the design from first principles like real system designers. We start from the problem statement of efficiently storing virtual address mappings and performing lookups efficiently, and from there, we iteratively arrive at the final solution that looks like modern-day page tables. I believe that this way, not only you would understand page tables better, but also develop the design chops needed to build solutions in other domains.

In the next video, we will talk about protection bits in virtual pages. Till then, if you haven’t read the original article/book, I recommend checking that out. You can also get it in the form of a beautiful PDF for offline reading using the link below.

Get Virtual Memory Ebook

User's avatar

Continue reading this post for free, courtesy of Abhinav Upadhyay.