As the end of the 1990s approached, a lot of kernel-development effort was going into improving support for 32-bit systems with shockingly large amounts of memory installed. This being the 1990s, having more than 1GB of memory in such a system was deemed to be shocking. Many of the compromises made to support such inconceivably large systems have remained in the kernel to this day. One of those compromises — bounce buffering of I/O requests in the block layer — has finally been eased out for the 6.16 release, more than a quarter-century after its introduction.
到了 1990 年代末期,内核开发者投入了大量精力来改进对安装了“惊人”内存容量的 32 位系统的支持。彼时,系统内存超过 1GB 被视为难以置信。为支持这些超乎想象的大内存系统所做的诸多妥协,有些直到今天仍存在于内核中。其中一个妥协就是块层中 I/O 请求的 bounce buffering(跳转缓冲),它终于在 6.16 版本中被淘汰——这项机制距今已存在了超过四分之一个世纪。
A 32-bit pointer can only address 4GB of memory, putting a hard limit on the size of the address space that a program on such a system can use. Linux, though, includes a couple of architectural choices that limited the amount of useful memory much more severely. The 4GB virtual address space contained both user and kernel-space memory; separating those spaces would have made more virtual address space available, but at a huge performance cost. The kernel also mapped all of physical memory into its portion of the address space, making it easy for the kernel to directly access every page in the system. That meant that the kernel's portion of the address space had to be larger than the amount of physical memory that the kernel managed.
32 位指针最多只能寻址 4GB 的内存,这就为程序可用的地址空间设置了一个硬性上限。但 Linux 的一些架构设计选择进一步加剧了可用内存的限制。4GB 的虚拟地址空间要容纳用户空间和内核空间;虽然如果将两者完全分离可以扩大可用地址范围,但那样会带来巨大的性能损耗。此外,内核还将所有物理内存映射到它自己的地址空间中,便于内核直接访问系统中的每个页面。这就意味着,内核空间的虚拟地址范围必须大于其管理的物理内存容量。
Most configurations in those days set aside the uppermost 1GB of virtual address space for the kernel, leaving 3GB for user space. But, since the kernel required that all of physical memory be mapped into its space, it could only make use of rather less than 1GB of
4万+




被折叠的 条评论
为什么被折叠?



