简体   繁体   中英

Mapping between virtual and physical address in memory paging

In some system, paging mapped a virtual address (a8b43f​​) 16 to a physical address (13efd43f) 16 .

What can be inferred about the page size?

While this is not enough information to determine anything for certain, you can infer an upper limit on the page size by noting that the lower 13 bits of both addresses are the same. As we know the page index is the lower x bits of the address, if we find the maximum page index, we can determine the maximum page size. 0x00A8B43F and 0x13EFD43F share the same lower 13-bits ('b1_0100_0011_1111). Thus, the maximum the page size can be is 2^13 words, or 8 kwords. If the memory is byte addressable, this means a page size of 8KB.

However, without more information, knowing the exact page size is not possible as the shared bits might have come from a convenient mapping.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM