Memory overhead of HVM domains
I think difference between like 256 ~ 512 ~ 1024 is reasonable, sfor example, 512M ram requires about 512k p2m table size.
So the point is the size for 16M vmx domain. If we need to investigate that size, maybe we can calculate each item one by one, including: 1:1 mapping table, shadow, p2m, shadow cache. Anything else left?
Yunhong Jiang
Quoted 103 lines
-----Original Message-----
From: Charles Coffing [mailto:[email protected]]
Sent: 2006年4月11日 15:17
To: Jiang, Yunhong; [email protected]
Subject: RE: [Xen-devel] Memory overhead of HVM domainsQuoted 1 line · Yunhong
From you definition of overhead, I think your overhead should include
the
Quoted 1 line
shadow page table, p2m table and those shadow cache, am I right?
Right. But 10 to 14 MB** for just a 16 MB domU seems excessive for these things, doesn't it?
** my numbers below minus 4 MB for video
Quoted 3 lines
Not sure if any other sources.
Also I just find a bug on qemu, which may occupy double size of the
video
Quoted 1 line
memory if you are using Xwindow.
That might help explain it, thanks.
Quoted 6 lines
Thanks
Yunhong Jiang--- Original Message-----
Quoted 2 lines
From: xen- devel- [email protected]
[mailto:xen- devel- [email protected]] On Behalf Of CharlesCoffing
Quoted 7 lines
Quoted 7 lines
Sent: 2006年4月11日 12:43
To: xen- [email protected]
Subject: [Xen- devel] Memory overhead of HVM domainsHi,
I was trying to find a solution for bug #521 ("video ram for hvm
guests not
Quoted 1 line
Quoted 1 line
properly accounted for when ballooning"). The trivial (although
ugly) answer
Quoted 1 line
Quoted 1 line
is to allocate an extra (hard- coded) 1026 pages in the
getDomainMemory()Quoted 1 line
Quoted 1 line
function to account for the
increase_reservationthat qemu- dm willdo.
Quoted 2 lines
Quoted 2 lines
However, ugly or not, this doesn't work. In reality, an HVM domain
requires
Quoted 1 line
Quoted 1 line
some extra memory in addition to its nominal memory size. Here are
some
Quoted 1 line
Quoted 1 line
measurements I did (everything in MB; overhead is approximate and
measured by
Quoted 1 line
Quoted 1 line
looking at memory remaining in Xen's DMA and DOM memory zones before
and
Quoted 12 lines
after
Quoted 11 lines
creating the HVM domU):
Nominal Overhead
------- -------- 16 14.2 128 16.3 256 16.6 512 17.1 1024 18.44 MB of this is due to the VM's video memory. I expect additional
state
Quoted 2 lines
would
Quoted 1 line
be stored in the qemu- dm process, but that would consume already-
allocated dom0
Quoted 1 line
Quoted 1 line
memory, and so wouldn't be represented above. I also see references
to VMCBs
Quoted 1 line
Quoted 1 line
/ VMCSs, but those are getting allocated on Xen's heap, and so also
not
Quoted 7 lines
Quoted 7 lines
represented above.
So several questions:
1. Where's the extra memory going?
2. Should we even try to calculate it for auto- ballooning? It seems
like many
Quoted 1 line
Quoted 1 line
factors could affect it, and any such calculation would be very
brittle.
Quoted 2 lines
Quoted 2 lines
I'll gladly code up and test a patch to auto- balloon for HVM
domains, but I
Quoted 12 lines
first
Quoted 11 lines
want to understand what's going on.
Thanks,
Chuck_______________________________________________
Xen- devel mailing list
Xen- [email protected]
http://lists.xensource.com/xen- devel