From my understanding of how virtual address translation happens (assuming a 32 bit virtual address space, as in the x86 architecture):
- bits 31:22 of the virtual address indicate the proper Page Directory Entry (i.e. aligned physical address of the Page Table) to access
- similarly, bits 21:12 of the virtual address indicate the proper Page Table Entry (i.e. aligned physical address of the Page itself) to access
- lastly, bits 11:0 indicate the proper offset into the Page, and are merely appended onto the end of the final physical address to access
As for the physical address
- bits 31:12 are the physical base address (aligned) of the Page (found from the PTE)
- bits 11:0 are the same as they are in the virtual address
Visually, this is what happens
I know that a Page is a chunk of virtual memory. But conceptually, I have a hard time visualizing what is actually "inside" of a Page. Ie, if I were to index into a "Page entry" (if such a thing even makes sense), what would I get in return?
This post seems to refer this value as a "desired byte." What exactly is the "desired byte"? Am I overthinking the functionality of Pages?