本文概述
物理地址空间
系统中的物理地址空间可以定义为主存储器的大小。将进程大小与物理地址空间进行比较非常重要。进程大小必须小于物理地址空间。
Physical Address Space = Size of the Main Memory
If, physical address space = 64 KB = 2 ^ 6 KB = 2 ^ 6 X 2 ^ 10 Bytes = 2 ^ 16 bytes
Let us consider, word size = 8 Bytes = 2 ^ 3 Bytes
Hence, Physical address space (in words) = (2 ^ 16) / (2 ^ 3) = 2 ^ 13 Words
Therefore, Physical Address = 13 bits
In General, If, Physical Address Space = N Words
then, Physical Address = log2 N
逻辑地址空间
逻辑地址空间可以定义为进程的大小。进程的大小应足够小, 以便可以驻留在主内存中。
比方说
Logical Address Space = 128 MB = (2 ^ 7 X 2 ^ 20) Bytes = 2 ^ 27 Bytes
Word size = 4 Bytes = 2 ^ 2 Bytes
Logical Address Space (in words) = (2 ^ 27) / (2 ^ 2) = 2 ^ 25 Words
Logical Address = 25 Bits
In general, If, logical address space = L words
Then, Logical Address = Log2L bits
什么是单词?
字是内存的最小单位。它是字节的集合。在分析输入到解码器的n位地址和由解码器产生的2 ^ n个存储位置之后, 每个操作系统都会定义不同的字长。
评论前必须登录!
注册