Warning: file_get_contents(/data/phpspider/zhask/data//catemap/4/unix/3.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
C 为什么在XV6中,常量PHYSTOP被定义为0xE000000?_C_Unix_Operating System_Xv6 - Fatal编程技术网

C 为什么在XV6中,常量PHYSTOP被定义为0xE000000?

C 为什么在XV6中,常量PHYSTOP被定义为0xE000000?,c,unix,operating-system,xv6,C,Unix,Operating System,Xv6,据我所知,在XV6中,PHYSTOP应该是1GB 如果是这样,PHYSTOP应该是0x40000000(1GB),而不是0xE000000(224MB),如中所示: 此外,在XV6中,进程可能从0映射到0x8000000(KERNBASE)。也就是说,进程可能使用2GB地址空间。如果PHYSTOP不是2GB,怎么可能呢 我缺少什么?PHYSTOP是一个常量,出于性能原因定义为0xE000000 如果PHYSTOP设置得更高,则需要使用mappages映射所有可用内存。如今,操作系统动态地映射免费

据我所知,在XV6中,PHYSTOP应该是1GB

如果是这样,PHYSTOP应该是0x40000000(1GB),而不是0xE000000(224MB),如中所示:

此外,在XV6中,进程可能从0映射到0x8000000(KERNBASE)。也就是说,进程可能使用2GB地址空间。如果PHYSTOP不是2GB,怎么可能呢


我缺少什么?

PHYSTOP
是一个常量,出于性能原因定义为0xE000000

如果
PHYSTOP
设置得更高,则需要使用
mappages
映射所有可用内存。如今,操作系统动态地映射免费页面,而在xv6上,我们将它们映射到操作系统初始化上。映射2GB很慢

请注意,您可以在编译更大的虚拟内存之前更改此值

0203 #define PHYSTOP 0xE000000 // Top physical memory