Working with Tiered Memory

Memory Machine's transparent memory service enables applications such as KVM to directly allocate memory from two-tiered memory consisting of DRAM and PMem. Because persistent memory (PMem) is slower than volatile memory (DRAM), the Memory Machine software can use DRAM as a performance tier, to speed up the application running in the virtual machine (VM). More DRAM tier memory (up to the total memory consumed by the application) yields faster performance. But since DRAM is a limited resource, each VM should use just enough DRAM to gain acceptable performance and no more.

Memory Machine enables you to change the amount of tiering DRAM without stopping the VM. This makes it faster to investigate the effect of DRAM allotment on performance and easier to adjust DRAM levels to VM workload.

Besides the amount of DRAM available for tiering, the size of the tiering buffer pages has a large effect on performance. The Memory Machine memory allocator can be configured to use 2MB Linux HugePages pages to tier data between PMem and DRAM.

You can turn HugePages on or off dynamically at the same time you change DRAM tier. To turn HugePages on you must first set DRAM tier to zero to clear the paging buffer, since the memory allocator cannot use two different page sizes at once.

The follow sections explain how to control DRAM tiering levels and HugePages, then give examples of common use cases.