Add QMP command to allow management software to query for CPU information for the running host. The data returned by the command is in the form of a dictionary of QOM properties. This series depends on the "Add runnability info to query-cpu-definitions" series I sent 2 weeks ago. Git tree: https://github.com/ehabkost/qemu-hacks.git work/query-host-cpu Example output for x86: { "qom-properties": { "pfthreshold": false, "pku": false, "rtm": false, "tsc-deadline": true, "xstore-en": false, "cpuid-0xb": true, "abm": true, "ia64": false, "kvm-mmu": false, "xsaveopt": true, "hv-spinlocks": -1, "hotpluggable": true, "tce": false, "smep": true, "nx": true, "xcrypt": false, "sse4_2": true, "clflush": true, "sse4_1": true, "flushbyasid": false, "kvm-steal-time": true, "host-cache-info": false, "tsc": true, "adx": false, "ds": false, "fxsr": true, "tm": false, "hv-relaxed": false, "pclmuldq": true, "xgetbv1": false, "xstore": false, "migratable": true, "vme": true, "vendor": "GenuineIntel", "arat": true, "ffxsr": false, "de": true, "aes": true, "pse": true, "ds-cpl": false, "tbm": false, "sse": true, "phe-en": false, "f16c": true, "hotplugged": true, "mpx": false, "tsc-adjust": true, "avx512f": false, "avx2": true, "misalignsse": false, "level": 13, "pbe": false, "cx16": true, "avx512pf": false, "movbe": true, "perfctr-nb": false, "enforce": false, "ospke": false, "pmu": true, "fma4": false, "stepping": 1, "feature-words": [ { "cpuid-register": "EAX", "cpuid-input-eax": 6, "features": 4 }, { "cpuid-register": "EAX", "cpuid-input-eax": 13, "features": 1, "cpuid-input-ecx": 1 }, { "cpuid-register": "EDX", "cpuid-input-eax": 2147483658, "features": 0 }, { "cpuid-register": "EAX", "cpuid-input-eax": 1073741825, "features": 16777467 }, { "cpuid-register": "EDX", "cpuid-input-eax": 3221225473, "features": 0 }, { "cpuid-register": "EDX", "cpuid-input-eax": 2147483655, "features": 0 }, { "cpuid-register": "ECX", "cpuid-input-eax": 2147483649, "features": 33 }, { "cpuid-register": "EDX", "cpuid-input-eax": 2147483649, "features": 739248128 }, { "cpuid-register": "ECX", "cpuid-input-eax": 7, "features": 0, "cpuid-input-ecx": 0 }, { "cpuid-register": "EBX", "cpuid-input-eax": 7, "features": 1963, "cpuid-input-ecx": 0 }, { "cpuid-register": "ECX", "cpuid-input-eax": 1, "features": 4160369155 }, { "cpuid-register": "EDX", "cpuid-input-eax": 1, "features": 260832255 } ], "sse4a": false, "i64": true, "xsave": true, "hv-runtime": false, "pmm": false, "hle": false, "hv-crash": false, "est": false, "xop": false, "smx": false, "tsc-scale": false, "monitor": false, "avx512er": false, "apic": true, "sse4.1": true, "sse4.2": true, "hv-vapic": false, "pause-filter": false, "lahf-lm": true, "kvm-nopiodelay": true, "acpi": false, "mmx": true, "osxsave": false, "pcommit": false, "clwb": false, "dca": false, "pdcm": false, "xcrypt-en": false, "3dnow": false, "invtsc": false, "tm2": false, "hv-time": false, "hypervisor": true, "kvmclock-stable-bit": true, "xlevel": 2147483656, "fxsr-opt": false, "pcid": true, "lbrv": false, "wdt": false, "svm-lock": false, "popcnt": true, "nrip-save": false, "x2apic": true, "kvmclock": true, "smap": false, "pdpe1gb": true, "family": 6, "xlevel2": 0, "dtes64": false, "xd": true, "ace2": false, "xtpr": false, "lwp": false, "sep": true, "msr": true, "syscall": true, "decodeassists": false, "perfctr-core": false, "pge": true, "pn": false, "fma": true, "nodeid-msr": false, "hv-vpindex": false, "cx8": true, "mce": true, "avx512cd": false, "cr8legacy": false, "mca": true, "pni": true, "hv-vendor-id": "", "rdseed": false, "osvw": false, "fsgsbase": true, "model-id": "Intel(R) Core(TM) i7-4600U CPU @ 2.10GHz", "cmp-legacy": false, "kvm-pv-unhalt": true, "rdtscp": true, "mmxext": false, "cid": false, "type": "host-x86_64-cpu", "vmx": false, "ssse3": true, "extapic": false, "pse36": true, "mtrr": true, "ibs": false, "avx": true, "ace2-en": false, "invpcid": true, "bmi2": true, "vmcb-clean": false, "erms": true, "cmov": true, "check": true, "parent_bus": "", "clflushopt": false, "pat": true, "hv-synic": false, "hv-stimer": false, "3dnowprefetch": false, "fpu": true, "pae": true, "hv-reset": false, "skinit": false, "kvm": true, "pmm-en": false, "phe": false, "3dnowext": false, "ht": false, "tsc-frequency": 0, "kvm-pv-eoi": true, "npt": false, "apic-id": -1, "xsavec": false, "lm": true, "pclmulqdq": true, "svm": false, "sse3": true, "sse2": true, "ss": true, "topoext": false, "rdrand": true, "bmi1": true, "kvm-asyncpf": true, "xsaves": false, "model": 69 } } Eduardo Habkost (3): qmp: Add query-host-cpu command target-i386: Introduce x86_cpu_load_host_data() function target-i386: Implement arch_query_host_cpu_info() include/sysemu/arch_init.h | 1 + qapi-schema.json | 36 +++++++++++++++++ qmp-commands.hx | 6 +++ qmp.c | 13 ++++++ stubs/Makefile.objs | 1 + stubs/arch-query-host-cpu-info.c | 8 ++++ target-i386/cpu.c | 87 ++++++++++++++++++++++++++++++++++++---- 7 files changed, 145 insertions(+), 7 deletions(-) create mode 100644 stubs/arch-query-host-cpu-info.c -- 2.5.5 -- libvir-list mailing list libvir-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/libvir-list