PAE(物理地址扩展)如何实现大于4GB的地址空间? [英] How does PAE (Physical Address Extension) enable an address space larger than 4GB?

查看:38
本文介绍了PAE(物理地址扩展)如何实现大于4GB的地址空间?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

维基百科关于物理地址扩展的文章摘录:

An excerpt of Wikipedia's article on Physical Address Extension:

x86 处理器硬件架构增加了用于选择额外内存的额外地址线,因此物理地址大小从 32 位增加到 36 位.理论上,这会将最大物理内存大小从 4 GB 增加到 64 GB.

x86 processor hardware-architecture is augmented with additional address lines used to select the additional memory, so physical address size increases from 32 bits to 36 bits. This, theoretically, increases maximum physical memory size from 4 GB to 64 GB.

连同解释机制的图像:

但是我看不到地址空间是如何从 4GB 扩展到 64GB 的.而且 4 * 512 * 512 * 4K 仍然等于 4GB,不是吗?

But I can't see how the address space is expanded from 4GB to 64GB. And 4 * 512 * 512 * 4K still equals 4GB, isn't it?

推荐答案

在 32 位模式下运行的 x86 处理器使用内存地址的页面转换.这意味着在代码(内核和用户模式)使用的地址和实际物理内存之间存在一个映射层.例如.在 Windows 中,所有进程都将 .exe 文件的映像映射到相同的地址.

x86 processors running in 32-bit mode uses page translations for memory addresses. This means that there is a mapping layer between the address used by the code (both kernel and user mode) and the actual physical memory. E.g. in Windows all processes map the image of the .exe file to the same address.

虚拟地址和物理地址之间的映射层通常只能映射4GB的内存.启用 PAE 后,32 位虚拟地址映射到 36 位物理地址.尽管如此,单个进程一次不能访问超过 4GB.这就是您在粘贴的图像中看到的内容,即一个进程的 32 位地址空间.还可以看到包含物理地址的PTE(Page Table Entry)是64位宽的.

The mapping layer between the virtual and physical addresses can normally only map 4GB of memory. With PAE enabled, the 32 bit virtual addresses are mapped 36 bit physical addresses. Still, a single process cannot access more than 4GB at a single time. That's what you see in the image you've pasted, the 32-bit address space of one process. You can also see that the PTE (Page Table Entry) containing the physical address is 64 bit wide.

PAE 感知应用程序可以将内存的不同部分换入和换出可见地址空间,以使用超过 4GB 的 RAM,但它在任何单个时间点只能看到 4GB.

A PAE aware application can swap in and out different parts of memory into the visible address space to make use of more than 4GB of RAM, but it can only see 4GB at any single point in time.

这篇关于PAE(物理地址扩展)如何实现大于4GB的地址空间?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆