next up previous contents index
Next: 17.2 API reference Up: 17 Simple Virtual Memory: Previous: 17 Simple Virtual Memory:

17.1 Introduction

The Simple Virtual Memory (SVM) component provides very simple virtual memory management routines that are somewhat more application friendly than the extremely basic support provided by the kernel library (see Section 10.9.11). Applications are able to allocate large contiguous blocks of virtual memory that are backed by physical memory. Applications may also control the page level protection of memory. In addition, there is optional pageout support that allows the application to allocate more virtual memory than physical memory on machines where a disk swap partition is available. The SVM component is thread safe, although only a single virtual memory context is provided; all threads share the same set of page tables.

The SVM manager makes use of the list-based memory manager (LMM) (see Section 15), the address map manager (AMM) (see Section 16), and the page directory support in the kernel library. The LMM is used to to control physical memory, while the AMM is used to control the virtual memory mappings. The kernel paging support handles the details of manipulating the low level page tables. As a result, the SVM manager is very simple in its construction.

Although on the surface it might appear that the SVM provides generalized VM support, nothing could be further from the truth. What is provided is a means to allocate memory in the range above existing physical memory, and map those ranges to physical pages. With paging enabled, the application is able to use more virtual memory than physical memory. It should be noted that the kernel remains where it was initially loaded, and that unused pages of physical memory are left accessible by the application.



University of Utah Flux Research Group