mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-12-22 05:35:25 +00:00
tests: convert x86_64 tests to query-cpus-fast
All supported versions of QEMU include the query-cpus-fast QMP command. In preparation for dropping support for the old "query-cpus" commands, convert the JSON output for x86 tests to the new format, and drop the "halted" field from the expected output as it is not available anymore. The CPU properties were obtained from the query-hotpluggable-cpus output in tests/qemumonitorjsondata. CPU, thread_id, and qom_path are renamed respectively to cpu-index, qom-path and thread-id, while nip and halted are removed. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Reviewed-by: Peter Krempa <pkrempa@redhat.com>
This commit is contained in:
parent
eb98eb0ce8
commit
332ea27164
@ -3,47 +3,62 @@
|
|||||||
{
|
{
|
||||||
"arch": "x86",
|
"arch": "x86",
|
||||||
"current": true,
|
"current": true,
|
||||||
"CPU": 0,
|
"cpu-index": 0,
|
||||||
"qom_path": "/machine/unattached/device[0]",
|
"props": {
|
||||||
"pc": -2130415978,
|
"core-id": 0,
|
||||||
"halted": true,
|
"thread-id": 0,
|
||||||
"thread_id": 518291
|
"socket-id": 0
|
||||||
|
},
|
||||||
|
"qom-path": "/machine/unattached/device[0]",
|
||||||
|
"thread-id": 518291
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"arch": "x86",
|
"arch": "x86",
|
||||||
"current": false,
|
"current": false,
|
||||||
"CPU": 1,
|
"cpu-index": 1,
|
||||||
"qom_path": "/machine/unattached/device[2]",
|
"props": {
|
||||||
"pc": -2130415978,
|
"core-id": 1,
|
||||||
"halted": true,
|
"thread-id": 0,
|
||||||
"thread_id": 518292
|
"socket-id": 0
|
||||||
|
},
|
||||||
|
"qom-path": "/machine/unattached/device[2]",
|
||||||
|
"thread-id": 518292
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"arch": "x86",
|
"arch": "x86",
|
||||||
"current": false,
|
"current": false,
|
||||||
"CPU": 2,
|
"cpu-index": 2,
|
||||||
"qom_path": "/machine/unattached/device[3]",
|
"props": {
|
||||||
"pc": -2130415978,
|
"core-id": 1,
|
||||||
"halted": true,
|
"thread-id": 1,
|
||||||
"thread_id": 518294
|
"socket-id": 0
|
||||||
|
},
|
||||||
|
"qom-path": "/machine/unattached/device[3]",
|
||||||
|
"thread-id": 518294
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"arch": "x86",
|
"arch": "x86",
|
||||||
"current": false,
|
"current": false,
|
||||||
"CPU": 3,
|
"cpu-index": 3,
|
||||||
"qom_path": "/machine/unattached/device[4]",
|
"props": {
|
||||||
"pc": -2130415978,
|
"core-id": 0,
|
||||||
"halted": true,
|
"thread-id": 0,
|
||||||
"thread_id": 518295
|
"socket-id": 1
|
||||||
|
},
|
||||||
|
"qom-path": "/machine/unattached/device[4]",
|
||||||
|
"thread-id": 518295
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"arch": "x86",
|
"arch": "x86",
|
||||||
"current": false,
|
"current": false,
|
||||||
"CPU": 4,
|
"cpu-index": 4,
|
||||||
"qom_path": "/machine/unattached/device[5]",
|
"props": {
|
||||||
"pc": -2130415978,
|
"core-id": 0,
|
||||||
"halted": true,
|
"thread-id": 1,
|
||||||
"thread_id": 518296
|
"socket-id": 1
|
||||||
|
},
|
||||||
|
"qom-path": "/machine/unattached/device[5]",
|
||||||
|
"thread-id": 518296
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"id": "libvirt-22"
|
"id": "libvirt-22"
|
||||||
|
@ -7,7 +7,6 @@
|
|||||||
type='qemu64-x86_64-cpu'
|
type='qemu64-x86_64-cpu'
|
||||||
qom_path='/machine/unattached/device[0]'
|
qom_path='/machine/unattached/device[0]'
|
||||||
topology: socket='0' core='0' thread='0' vcpus='1'
|
topology: socket='0' core='0' thread='0' vcpus='1'
|
||||||
halted
|
|
||||||
[vcpu libvirt-id='1']
|
[vcpu libvirt-id='1']
|
||||||
online=yes
|
online=yes
|
||||||
hotpluggable=no
|
hotpluggable=no
|
||||||
@ -17,7 +16,6 @@
|
|||||||
type='qemu64-x86_64-cpu'
|
type='qemu64-x86_64-cpu'
|
||||||
qom_path='/machine/unattached/device[2]'
|
qom_path='/machine/unattached/device[2]'
|
||||||
topology: socket='0' core='0' thread='1' vcpus='1'
|
topology: socket='0' core='0' thread='1' vcpus='1'
|
||||||
halted
|
|
||||||
[vcpu libvirt-id='2']
|
[vcpu libvirt-id='2']
|
||||||
online=yes
|
online=yes
|
||||||
hotpluggable=no
|
hotpluggable=no
|
||||||
@ -27,7 +25,6 @@
|
|||||||
type='qemu64-x86_64-cpu'
|
type='qemu64-x86_64-cpu'
|
||||||
qom_path='/machine/unattached/device[3]'
|
qom_path='/machine/unattached/device[3]'
|
||||||
topology: socket='0' core='1' thread='0' vcpus='1'
|
topology: socket='0' core='1' thread='0' vcpus='1'
|
||||||
halted
|
|
||||||
[vcpu libvirt-id='3']
|
[vcpu libvirt-id='3']
|
||||||
online=yes
|
online=yes
|
||||||
hotpluggable=no
|
hotpluggable=no
|
||||||
@ -37,7 +34,6 @@
|
|||||||
type='qemu64-x86_64-cpu'
|
type='qemu64-x86_64-cpu'
|
||||||
qom_path='/machine/unattached/device[4]'
|
qom_path='/machine/unattached/device[4]'
|
||||||
topology: socket='0' core='1' thread='1' vcpus='1'
|
topology: socket='0' core='1' thread='1' vcpus='1'
|
||||||
halted
|
|
||||||
[vcpu libvirt-id='4']
|
[vcpu libvirt-id='4']
|
||||||
online=yes
|
online=yes
|
||||||
hotpluggable=no
|
hotpluggable=no
|
||||||
@ -47,7 +43,6 @@
|
|||||||
type='qemu64-x86_64-cpu'
|
type='qemu64-x86_64-cpu'
|
||||||
qom_path='/machine/unattached/device[5]'
|
qom_path='/machine/unattached/device[5]'
|
||||||
topology: socket='1' core='0' thread='0' vcpus='1'
|
topology: socket='1' core='0' thread='0' vcpus='1'
|
||||||
halted
|
|
||||||
[vcpu libvirt-id='5']
|
[vcpu libvirt-id='5']
|
||||||
online=no
|
online=no
|
||||||
hotpluggable=yes
|
hotpluggable=yes
|
||||||
|
@ -9,11 +9,9 @@
|
|||||||
"node-id": 0,
|
"node-id": 0,
|
||||||
"socket-id": 0
|
"socket-id": 0
|
||||||
},
|
},
|
||||||
"CPU": 0,
|
"cpu-index": 0,
|
||||||
"qom_path": "/machine/unattached/device[0]",
|
"qom-path": "/machine/unattached/device[0]",
|
||||||
"pc": 1048956,
|
"thread-id": 2033724
|
||||||
"halted": true,
|
|
||||||
"thread_id": 2033724
|
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"arch": "x86",
|
"arch": "x86",
|
||||||
@ -24,11 +22,9 @@
|
|||||||
"node-id": 1,
|
"node-id": 1,
|
||||||
"socket-id": 0
|
"socket-id": 0
|
||||||
},
|
},
|
||||||
"CPU": 1,
|
"cpu-index": 1,
|
||||||
"qom_path": "/machine/unattached/device[2]",
|
"qom-path": "/machine/unattached/device[2]",
|
||||||
"pc": 1037318,
|
"thread-id": 2033725
|
||||||
"halted": true,
|
|
||||||
"thread_id": 2033725
|
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"id": "libvirt-21"
|
"id": "libvirt-21"
|
||||||
|
@ -7,7 +7,6 @@
|
|||||||
type='Broadwell-x86_64-cpu'
|
type='Broadwell-x86_64-cpu'
|
||||||
qom_path='/machine/unattached/device[0]'
|
qom_path='/machine/unattached/device[0]'
|
||||||
topology: socket='0' core='0' thread='0' node='0' vcpus='1'
|
topology: socket='0' core='0' thread='0' node='0' vcpus='1'
|
||||||
halted
|
|
||||||
[vcpu libvirt-id='1']
|
[vcpu libvirt-id='1']
|
||||||
online=yes
|
online=yes
|
||||||
hotpluggable=no
|
hotpluggable=no
|
||||||
@ -17,7 +16,6 @@
|
|||||||
type='Broadwell-x86_64-cpu'
|
type='Broadwell-x86_64-cpu'
|
||||||
qom_path='/machine/unattached/device[2]'
|
qom_path='/machine/unattached/device[2]'
|
||||||
topology: socket='0' core='0' thread='1' node='1' vcpus='1'
|
topology: socket='0' core='0' thread='1' node='1' vcpus='1'
|
||||||
halted
|
|
||||||
[vcpu libvirt-id='2']
|
[vcpu libvirt-id='2']
|
||||||
online=no
|
online=no
|
||||||
hotpluggable=yes
|
hotpluggable=yes
|
||||||
|
@ -3114,9 +3114,9 @@ mymain(void)
|
|||||||
DO_TEST_CPU_DATA("full");
|
DO_TEST_CPU_DATA("full");
|
||||||
DO_TEST_CPU_DATA("ecx");
|
DO_TEST_CPU_DATA("ecx");
|
||||||
|
|
||||||
DO_TEST_CPU_INFO("x86-basic-pluggable", 8);
|
DO_TEST_CPU_INFO_FAST("x86-basic-pluggable", 8);
|
||||||
DO_TEST_CPU_INFO_FAST("x86-full", 11);
|
DO_TEST_CPU_INFO_FAST("x86-full", 11);
|
||||||
DO_TEST_CPU_INFO("x86-node-full", 8);
|
DO_TEST_CPU_INFO_FAST("x86-node-full", 8);
|
||||||
DO_TEST_CPU_INFO_FAST("x86-dies", 16);
|
DO_TEST_CPU_INFO_FAST("x86-dies", 16);
|
||||||
|
|
||||||
DO_TEST_CPU_INFO_FAST("ppc64-basic", 24);
|
DO_TEST_CPU_INFO_FAST("ppc64-basic", 24);
|
||||||
|
Loading…
Reference in New Issue
Block a user