RFC Memory merging driver for Linux
Get series with b4
b4 am [email protected]Versions newest first
- v1 RFC Latest5 patches 18 repliesIn review
Patches in v1 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/5 | rmap: add new exported function: page_wrprotect()include/ mm/ | +98 | 1 reply | |
| 2/5 | add new exported function replace_page()include/ mm/ | +64 | 2 replies | |
| 3/5 | ksm source code | +0 | 8 replies | |
| 4/5 | example for userspace scanner | +0 | 0 replies | |
| 5/5 | example of userspace application register it memory in ksmqemu/ | +35 | 0 replies |
Reviews trailers per patch
1 of 5 patches has a Reviewed-by or Acked-by.
| Patch | Rik van Riel |
|---|---|
| 1/5 | A-b |
| 2/5 | |
| 3/5 | |
| 4/5 | |
| 5/5 |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.
Cover letter [RFC][PATCH 0/5] Memory merging driver for Linux
when kvm is used in production servers, many times it run the same guests operation systems more than once
the idea of this module is to find the identical pages in diffrent guests and to share them so we can save memory,
due to the fact that many guests run identical operation systems, alot of data in the ram is equal between the guests
this module find this identical data (pages) and merge them into one single page
this new page is write protected so in any case the guest will try to write to it do_wp_page will duplicate the page
this module simply go over a list of pages that were registered, and find the identical pages (using hash table)
the pages that it scan are anonymous, each time that it find an identical pages it create a file mapped
(right now it is just kernel allocated) page that will be the shared page,
as for now i am missing swapping support (will add soon using non-linear vmas)
this module can be used for every other purpuse and work without kvm (i used it for qemu)
to make it work for kvm, the mmu notifers sent by andrea should be used
i added 2 new functions to the kernel
one:page_wrprotect() make the page as read only by setting the ptes point to it as read only.
second:replace_page() - replace the pte mapping related to vm area between two pages
few numbers:
for started windows i can share almost the whole memory (as it zero all the pages),
so i can start much much more windows guests than i have memory (as long as no one touch it)
for linux guests i was able to share 800mb+ for 4 centos guests that each had 512mb memory allocated to
(again it was without work load, and they ran X)
Signature · 7 lines
woof. ------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2008. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/