KHB: Transparent support for large pages
Posted Jun 22, 2006 3:08 UTC (Thu) by
ianw (subscriber, #20143)
Parent article:
KHB: Transparent support for large pages
There is a lot of current work on superpages.
The current Linux approach to large pages is HugeTLB. This is a static approach, and not transparent. People are working on this with things like libhugetlbfs [1], and I have heard rumors of dynamic, per process hugetlb.
The other approach, as is mentioned, is one that is transparent. Naohiko Shimizu came up with an approach [2] which was implemented on Alpha, SPARC and i386. This showed good results, but the patch never ended up going anywhere.
Gelato@UNSW is activley working on large page support for Itanium Linux [3], using a Shimizu inspired approach. Itanium has excellent support for multiple page sizes, and with suitable modifications can use a hardware walker to re-fill the TLB with superpages with very little OS intervention. The project is currently in the hands of a master's student, but even with a hacked together proof of concept we can see great potential [4].
Clearly, as identified, fragmentation is an issue with larger pages. We are keeping an eye on the above mentioned projects, and others such as Chris Yeoh's work on fragmentation avoidance [5].
For Itanium, we believe we could get a working superpage implementation with very few overall lines of code difference, as mentioned. There is some doubt about how generic this could be; the Rice paper was implemented as a FreeBSD module using hooks into the VM layer; not an easy proposition with Linux.
Dynamic, transparent superpages are really not suited to the multi-level tree design as used by the Linux VM. There are a range of more suitable page table designs that incorporate support for large, spare address spaces and superpages. To this end, Gelato@UNSW are working on a page table abstraction interface [6]. One of the most promising approaches is a guarded page table [7], which we are actively developing behind our interface. Our long term goal is to marry a guarded page table with dynamic superpages.
If others are working in this area, please contact us at gelato@gelato.unsw.edu.au.
[1] http://lwn.net/Articles/171451/
[2] http://shimizu-lab.dt.u-tokai.ac.jp/lsp.html
[3] http://www.gelato.unsw.edu.au/IA64wiki/SuperPages
[4] http://www.gelato.unsw.edu.au/IA64wiki/Ia64SuperPages/Ben...
[5] http://ozlabs.org/~cyeoh/presentations/memory_management_...
[6] http://www.gelato.unsw.edu.au/IA64wiki/PageTableInterface
[7] http://www.gelato.unsw.edu.au/IA64wiki/GuardedPageTable
(
Log in to post comments)