[Libvir] libvirt statistics

Richard W.M. Jones rjones at redhat.com
Thu Sep 6 14:31:26 UTC 2007


Eduardo Habkost wrote:
> Hi,
> 
> On Thu, Sep 06, 2007 at 02:10:39PM +0100, Richard W.M. Jones wrote:
>> [Using `pahole' and friends - see 
>> http://git.kernel.org/?p=linux/kernel/git/acme/pahole.git;a=summary and 
>> https://ols2006.108.redhat.com/2007/Reprints/melo-Reprint.pdf ]
>>
>> These are all on x86-64.  You'll get slightly different results on a 32 
>> bit arch.
>>
>> Largest structures, by size:
>>
>> qemud_vm_def: 16608 4
>> qemud_vm_os_def: 16436 1
>> _testConn: 14504 2
> <snip>
> 
> What is the second field here?

Good question!  I had to look at the source code and it turns out the 
the second numeric field is the number of holes.

>> Structures with holes which could be made smaller by packaging (third 
>> number is how many bytes you'd save per allocation):
>>
> <snip>
>> _xmlValidCtxt                      112   104     8
>> _xmlEntity                         136   128     8
>> _xmlParserCtxt                     696   672    24
>> _testConn                        14504 14496     8
>> _xmlURI                             80    72     8
>> _xmlXPathObject                     72    56    16
>> _xmlXPathParserContext              80    72     8
>> _xmlXPathContext                   352   336    16
>> _xmlError                           88    80     8
>> _xmlAttr                            96    88     8
>> _xmlDoc                            168   160     8
>> _xmlNode                           120   112     8
> 
> Are those defined by libxml, or are they from the libvirt code?

They're in libxml2.  The way that the dwarves programs work is they 
consider the whole program or shared library, everything it contains and 
all dependent libraries down to libc.

>> enum /**/ virDrvOpenRemoteFlags; /* 0 */
> 
> I think this was supposed to be a type definition. The variable is
> never used.

Yes, it's a bug!  Patch coming up ...

Rich.

-- 
Emerging Technologies, Red Hat - http://et.redhat.com/~rjones/
Registered Address: Red Hat UK Ltd, Amberley Place, 107-111 Peascod
Street, Windsor, Berkshire, SL4 1TE, United Kingdom.  Registered in
England and Wales under Company Registration No. 03798903
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/x-pkcs7-signature
Size: 3237 bytes
Desc: S/MIME Cryptographic Signature
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20070906/59b00a98/attachment-0001.bin>


More information about the libvir-list mailing list