This is an old revision of the document!
FreeBSD/arm Superpages for ARMv7
Engineer
Mentor
Abstract
The objective of this project is to provide FreeBSD/arm with the superpages support.
Indicated functionality is intended to work on all ARMv7 based processors, however the reference hardware platform for this development would be a Pandaboard - a popular system, widely available, based on Cortex-A9 ARMv7 CPU core.
Problem description
ARM architecture is more and more prevailing, not only in the mobile and embedded space. Among the more interesting industry trends emerging in the recent months has been the “ARM server” concept. Some top tier companies started developing systems like this already (Dell, HP).
Key to FreeBSD success in these new areas are sophisticated features, among them are superpages, which allow for efficient use of TLB translations so they cover large physical regions, leading to improved performance in many applications and scalability.
Contemporary ARM architecture (ARMv7, the upcoming ARMv8) is already on on par with the traditional PC architecture in terms of advanced CPU features (MMU, multi level cache, TLB, multi core, hardware coherency and similar) and in particular can make use of transparent superpages support.
Milestones
| M1 | Clean-ups of pmap-v6.c module | 100% |
| M2 | Initial implementation of superpages on ARM | 70% |
| M3 | Performance measurements, testing, documentation | 0% |
| M4 | Final integration with the FreeBSD source repo | 50% |
Clean-ups of pmap-v6.c module
Completed tasks:
- Port of the PV entry allocator
- Switch to “AP[2:1]” access permissions model
- PTE based, page referenced/modified emulation
- Fixes regarding page replacement strategy
- Code optimizations and bug fixes
- Integration of the current work to the FreeBSD HEAD
- Implementation of the pmap_copy()
Initial implementation of superpages on ARM
Completed tasks:
- Support for multiple page sizes
- 4KB and 1MB section mappings are allowed
- Implement basic page promotion and demotion mechanisms
- Promotion to 1MB section
- Demotion from 1MB page to 4KB pages
- 1MB section creation and removal
- PV entry management for superpages
- Enable generic, reservation based allocation
Ongoing tasks:
- Bring-up of the functionality
- Adjust pmap-v6 infrastructure to utilize superpages' mechanisms
- Fix bugs
Repository
Currently there are two active branches in the repository.
In order to view commits on the desired branch, one has to switch to it using branch drop-down list.
Branches:
- armsp-dev
- most recent changes that are being tested at the moment
- armsp
- main project's branch
References/Links
Practical, transparent operating system support for superpages PAPER