The following echoes the way page tables are represented in the virtual address for FreeBSD (amd64)
// start by moving entries we care about to the bottom
vpn_table_entry = vpn >> (9*level);
// clear out any high order bits (sign extension)
vpn_table_entry &= (1ul << ((4 - level) * 9))...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.