开发者

How many bits are in a logical address?

Alright, so I've done some searching around Stack and cannot find the answer to this question. I开发者_JAVA百科t's something that was mentioned in class, but the professor did not specifically say how to go about figuring this out.

If we assume a system is 64bit, and has physical memory of 128GB, but we want processes to run as 256GB's, how can I calculate the bit required for logical address?

All the research I've done so far deals with physical memory of 2-4GB, and I cannot for the life of me figure out how to calculate this. I need to know this in order to understand displacement and entries of pages...


The number of bits needed doesn't depend only on the size of the process, it also depends on the number of bytes that each address points to.

The general formula is:

num_of_bits = ceiling(log_2(size_of_process_in_bytes / bytes_pointed_by_an_address))


Maybe this will help. Given a 32-Bit, we have: 2 to the 32nd power = 4 294 967 296 => 4GB Max address space accessible by 32-bit word length.

For a 64-Bit system, we have: 2 to the 64th power = 18 446 744 073 709 551 616 => 16EB (EB = exbibytes) Max address space accessible by 64-bit word length, which is practically unlimited, but we are constrained by hardware (e.g., My motherboard supports only 24GB max).

Hope this helps!

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜