[libvirt] [PATCH] Extend l3 cache to nodeinfo
Daniel P. Berrange
berrange at redhat.com
Tue Jan 10 12:08:03 UTC 2017
On Tue, Jan 10, 2017 at 12:05:00PM +0000, Qiao, Liyong wrote:
> Hi Daniel,
>
> Thanks for your comments.
>
> I will not change public ABI nor break RPC.
>
> I wonder if you would agree with extend virHostCPUGetInfoPopulateLinux to get l3 cache size ?
> Such as:
> virHostCPUGetInfoPopulateLinux(FILE *cpuinfo,
> virArch arch,
> unsigned int *cpus,
> unsigned int *mhz,
> unsigned int *nodes,
> unsigned int *sockets,
> unsigned int *cores,
> unsigned int *threads,
> unsigned int *l3_cache) ←---------
>
> virHostCPUGetInfoPopulateLinux is doing parsing /proc/cpuinfo , so I think it’s the best way to get l3 cache size.
>
> cat /proc/cpuinfo
/proc/cpuinfo is a pretty awful file because its contents are completely
different on every linux architecture. It would be preferrable to get
the cache sizes from /sys/devices/system/cpu/* if possible.
Regards,
Daniel
--
|: http://berrange.com -o- http://www.flickr.com/photos/dberrange/ :|
|: http://libvirt.org -o- http://virt-manager.org :|
|: http://entangle-photo.org -o- http://search.cpan.org/~danberr/ :|
More information about the libvir-list
mailing list