- Jan 04, 2022
-
-
Matheus Ferst authored
The non-signalling versions of VSX scalar convert to shorter/longer precision insns doesn't silence SNaNs in the hardware. To better match this behavior, use the non-arithmatic conversion of helper_todouble instead of float32_to_float64. A test is added to prevent future regressions. Signed-off-by:
Matheus Ferst <matheus.ferst@eldorado.org.br> Message-Id: <20211228120310.1957990-1-matheus.ferst@eldorado.org.br> Signed-off-by:
Cédric Le Goater <clg@kaod.org>
-
- Dec 31, 2021
-
-
Yanan Wang authored
Most machine types in test-smp-parse will be OK to have the default MIN/MAX CPUs except "smp-generic-invalid", let's keep the default values in machine_base_class_init which will be inherited. And if we hope a different value for a specific machine, modify it in its own initialization function. Signed-off-by:
Yanan Wang <wangyanan55@huawei.com> Reviewed-by:
Philippe Mathieu-Daudé <philmd@redhat.com> Message-Id: <20211228092221.21068-7-wangyanan55@huawei.com> Signed-off-by:
Philippe Mathieu-Daudé <philmd@redhat.com>
-
Yanan Wang authored
The default value of the MachineClass members is 0, which means we don't have to explicitly zero them. Also the value of "mc->smp_props.prefer_sockets" will be taken care of by smp_parse_test(), we don't necessarily need the statement in machine_base_class_init() either. Signed-off-by:
Yanan Wang <wangyanan55@huawei.com> Reviewed-by:
Philippe Mathieu-Daudé <philmd@redhat.com> Message-Id: <20211228092221.21068-6-wangyanan55@huawei.com> Signed-off-by:
Philippe Mathieu-Daudé <philmd@redhat.com>
-
Yanan Wang authored
Add testcases for parsing of the four-level CPU topology hierarchy, ie sockets/clusters/cores/threads, which will be supported on ARM virt machines. Signed-off-by:
Yanan Wang <wangyanan55@huawei.com> Reviewed-by:
Philippe Mathieu-Daudé <philmd@redhat.com> Message-Id: <20211228092221.21068-5-wangyanan55@huawei.com> Signed-off-by:
Philippe Mathieu-Daudé <philmd@redhat.com>
-
Philippe Mathieu-Daudé authored
All methods related to MachineState are prefixed with "machine_". smp_parse() does not need to be an exception. Rename it and const'ify the SMPConfiguration argument, since it doesn't need to be modified. Reviewed-by:
Andrew Jones <drjones@redhat.com> Reviewed-by:
Richard Henderson <richard.henderson@linaro.org> Reviewed-by:
Yanan Wang <wangyanan55@huawei.com> Tested-by:
Yanan Wang <wangyanan55@huawei.com> Signed-off-by:
Philippe Mathieu-Daudé <philmd@redhat.com> Message-Id: <20211216132015.815493-9-philmd@redhat.com>
-
Philippe Mathieu-Daudé authored
Declare structures const when we don't need to modify them at runtime. Reviewed-by:
Andrew Jones <drjones@redhat.com> Reviewed-by:
Richard Henderson <richard.henderson@linaro.org> Reviewed-by:
Yanan Wang <wangyanan55@huawei.com> Tested-by:
Yanan Wang <wangyanan55@huawei.com> Signed-off-by:
Philippe Mathieu-Daudé <philmd@redhat.com> Message-Id: <20211216132015.815493-8-philmd@redhat.com>
-
Philippe Mathieu-Daudé authored
We can simply use a local variable (and pass its pointer) instead of a pointer to a compound literal. Reviewed-by:
Andrew Jones <drjones@redhat.com> Reviewed-by:
Richard Henderson <richard.henderson@linaro.org> Reviewed-by:
Yanan Wang <wangyanan55@huawei.com> Tested-by:
Yanan Wang <wangyanan55@huawei.com> Signed-off-by:
Philippe Mathieu-Daudé <philmd@redhat.com> Message-Id: <20211216132015.815493-7-philmd@redhat.com>
-
Philippe Mathieu-Daudé authored
Keep the common TYPE_MACHINE class initialization in machine_base_class_init(), make it abstract, and move the non-common code to a new class: "smp-generic-valid". Reviewed-by:
Richard Henderson <richard.henderson@linaro.org> Signed-off-by:
Philippe Mathieu-Daudé <philmd@redhat.com> Reviewed-by:
Yanan Wang <wangyanan55@huawei.com> Message-Id: <20211216132015.815493-6-philmd@redhat.com>
-
Philippe Mathieu-Daudé authored
Avoid modifying the MachineClass internals by adding the 'smp-generic-invalid' machine, which inherits from TYPE_MACHINE. Reviewed-by:
Richard Henderson <richard.henderson@linaro.org> Signed-off-by:
Philippe Mathieu-Daudé <philmd@redhat.com> Reviewed-by:
Yanan Wang <wangyanan55@huawei.com> Message-Id: <20211216132015.815493-5-philmd@redhat.com>
-
Philippe Mathieu-Daudé authored
Avoid modifying the MachineClass internals by adding the 'smp-with-dies' machine, which inherits from TYPE_MACHINE. Reviewed-by:
Richard Henderson <richard.henderson@linaro.org> Reviewed-by:
Yanan Wang <wangyanan55@huawei.com> Tested-by:
Yanan Wang <wangyanan55@huawei.com> Signed-off-by:
Philippe Mathieu-Daudé <philmd@redhat.com> Message-Id: <20211216132015.815493-4-philmd@redhat.com>
-
Philippe Mathieu-Daudé authored
Split the 'generic' test in two tests: 'valid' and 'invalid'. This will allow us to remove the hack which modifies the MachineClass internal state. Reviewed-by:
Richard Henderson <richard.henderson@linaro.org> Reviewed-by:
Yanan Wang <wangyanan55@huawei.com> Signed-off-by:
Philippe Mathieu-Daudé <philmd@redhat.com> Message-Id: <20211216132015.815493-3-philmd@redhat.com>
-
Philippe Mathieu-Daudé authored
Use g_test_add_data_func() instead of g_test_add_func() so we can pass the machine type to the tests (we will soon have different machine types). Reviewed-by:
Richard Henderson <richard.henderson@linaro.org> Reviewed-by:
Yanan Wang <wangyanan55@huawei.com> Signed-off-by:
Philippe Mathieu-Daudé <philmd@redhat.com> Message-Id: <20211216132015.815493-2-philmd@redhat.com>
-
Richard Henderson authored
The parallel version of STBY did not take host endianness into account, and also computed the incorrect address for STBY_E. Bswap twice to handle the merge and store. Compute mask inside the function rather than as a parameter. Force align the address, rather than subtracting one. Generalize the function to system mode by using probe_access(). Cc: qemu-stable@nongnu.org Tested-by:
Helge Deller <deller@gmx.de> Reported-by:
Helge Deller <deller@gmx.de> Signed-off-by:
Richard Henderson <richard.henderson@linaro.org>
-
Richard Henderson authored
The cross-i386-tci test has timeouts because we're no longer applying the timeout that we desired. Hack around it. Reviewed-by:
Philippe Mathieu-Daudé <f4bug@amsat.org> Fixes: 23a77b2d ("build-system: clean up TCG/TCI configury") Signed-off-by:
Richard Henderson <richard.henderson@linaro.org>
-
Richard Henderson authored
Use $cpu instead of $ARCH, which has been removed from the top-level configure. Tested-by:
Philippe Mathieu-Daudé <f4bug@amsat.org> Reviewed-by:
Philippe Mathieu-Daudé <f4bug@amsat.org> Fixes: 823eb013 ("configure, meson: move ARCH to meson.build") Signed-off-by:
Richard Henderson <richard.henderson@linaro.org>
-
- Dec 28, 2021
-
-
Vladimir Sementsov-Ogievskiy authored
It's unused now (except for permission handling)[*]. The only reasonable user of it was block-stream job, recently updated to use own blk. And other block jobs prefer to use own source node related objects. So, the arguments of dropping the field are: - block jobs prefer not to use it - block jobs usually has more then one node to operate on, and better to operate symmetrically (for example has both source and target blk's in specific block-job state structure) *: BlockJob.blk is used to keep some permissions. We simply move permissions to block-job child created in block_job_create() together with blk. In mirror, we just should not care anymore about restoring state of blk. Most probably this code could be dropped long ago, after dropping bs->job pointer. Now it finally goes away together with BlockJob.blk itself. iotest 141 output is updated, as "bdrv_has_blk(bs)" check in qmp_blockdev_del() doesn't fail (we don't have blk now). Still, new error message looks even better. In iotest 283 we need to add a job id, otherwise "Invalid job ID" happens now earlier than permission check (as permissions moved from blk to block-job node). Signed-off-by:
Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com> Reviewed-by:
Nikita Lapshin <nikita.lapshin@virtuozzo.com>
-
Vladimir Sementsov-Ogievskiy authored
We are going to drop BlockJob.blk in further commit. For tests it's enough to simply pass bs pointer. Signed-off-by:
Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com> Reviewed-by:
Nikita Lapshin <nikita.lapshin@virtuozzo.com>
-
Vladimir Sementsov-Ogievskiy authored
Here we use job->blk to drop our own reference in job cleanup. Let's do simpler: drop our reference immediately after job creation. Signed-off-by:
Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com> Reviewed-by:
Nikita Lapshin <nikita.lapshin@virtuozzo.com>
-
- Dec 23, 2021
-
-
Paolo Bonzini authored
"meson test" starting with version 0.57 is just as capable and easy to use as QEMU's own TAP driver. All existing options for "make check" work. The only required code change involves how to mark "slow" tests; they need to belong to an additional "slow" suite. The rules for .tap output are replaced by JUnit XML; GitLab is able to parse that output and present it in the CI pipeline report. Signed-off-by:
Paolo Bonzini <pbonzini@redhat.com>
-
Vladimir Sementsov-Ogievskiy authored
Signed-off-by:
Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com> Reviewed-by:
Nikita Lapshin <nikita.lapshin@virtuozzo.com>
-
Vladimir Sementsov-Ogievskiy authored
Add qemu-io Popen constructor wrapper. To be used in the following new test commit. Signed-off-by:
Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com> Reviewed-by:
Nikita Lapshin <nikita.lapshin@virtuozzo.com>
-
Vladimir Sementsov-Ogievskiy authored
For qemu_io* functions support --image-opts argument, which conflicts with -f argument from qemu_io_args. For QemuIoInteractive use new wrapper as well, which allows relying on default format. Signed-off-by:
Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com> Reviewed-by:
Nikita Lapshin <nikita.lapshin@virtuozzo.com>
-
Vladimir Sementsov-Ogievskiy authored
Split qemu_tool_popen() from qemu_tool_pipe_and_status() to be used separately. Signed-off-by:
Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com> Reviewed-by:
Nikita Lapshin <nikita.lapshin@virtuozzo.com>
-
- Dec 22, 2021
-
-
Vladimir Sementsov-Ogievskiy authored
Add -j <JOBS> parameter, to run tests in several jobs simultaneously. For realization - simply utilize multiprocessing.Pool class. Notes: 1. Of course, tests can't run simultaneously in same TEST_DIR. So, use subdirectories TEST_DIR/testname/ and SOCK_DIR/testname/ instead of simply TEST_DIR and SOCK_DIR 2. multiprocessing.Pool.starmap function doesn't support passing context managers, so we can't simply pass "self". Happily, we need self only for read-only access, and it just works if it is defined in global space. So, add a temporary link TestRunner.shared_self during run_tests(). Signed-off-by:
Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com> Message-Id: <20211203122223.2780098-4-vsementsov@virtuozzo.com> Reviewed-by:
John Snow <jsnow@redhat.com> Tested-by:
John Snow <jsnow@redhat.com> Signed-off-by:
Hanna Reitz <hreitz@redhat.com>
-
Vladimir Sementsov-Ogievskiy authored
We are going to use do_run_test() in multiprocessing environment, where we'll not be able to change original runner object. Happily, the only thing we change is that last_elapsed and it's simple to do it in run_tests() instead. All other accesses to self in do_runt_test() and in run_test() are read-only. Signed-off-by:
Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com> Message-Id: <20211203122223.2780098-3-vsementsov@virtuozzo.com> Reviewed-by:
John Snow <jsnow@redhat.com> Tested-by:
John Snow <jsnow@redhat.com> Signed-off-by:
Hanna Reitz <hreitz@redhat.com>
-
Vladimir Sementsov-Ogievskiy authored
We are going to modify these methods and will add more documentation in further commit. As a preparation add basic documentation. Signed-off-by:
Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com> Message-Id: <20211203122223.2780098-2-vsementsov@virtuozzo.com> Reviewed-by:
John Snow <jsnow@redhat.com> Tested-by:
John Snow <jsnow@redhat.com> Signed-off-by:
Hanna Reitz <hreitz@redhat.com>
-
Thomas Huth authored
g_test_rand_int() must not be called before g_test_init(), otherwise the glib will show a "g_rand_int: assertion 'rand != NULL' failed" message in the log. So we could change the order here, but actually, it's safer to use g_file_open_tmp() anyway, so let's use that function now instead. Reported-by:
Philippe Mathieu-Daudé <philmd@redhat.com> Suggested-by:
Richard Henderson <richard.henderson@linaro.org> Message-Id: <20211222083652.776592-1-thuth@redhat.com> Signed-off-by:
Thomas Huth <thuth@redhat.com>
-
Thomas Huth authored
Machines might not always be compiled into the QEMU binary, so we should skip the test instead of failing if it is not available. Message-Id: <20211220081054.151515-5-thuth@redhat.com> Signed-off-by:
Thomas Huth <thuth@redhat.com>
-
Thomas Huth authored
Downstream users might want to disable legacy devices in their binaries, so we should not blindly assume that they are available. Add some proper checks before using them. Message-Id: <20211220081054.151515-4-thuth@redhat.com> Signed-off-by:
Thomas Huth <thuth@redhat.com>
-
Thomas Huth authored
The users might have built QEMU with less machines or without the i82378 superio device. Add some checks to the endianess-test so that it is able to deal with such stripped down QEMU versions, too. Message-Id: <20211220081054.151515-3-thuth@redhat.com> Signed-off-by:
Thomas Huth <thuth@redhat.com>
-
Thomas Huth authored
Devices might not always be compiled into the QEMU target binaries. We already have the libqos framework that is good for handling such situations, but some of the qtests are not a real good fit for the libqos framework. Let's add a qtest_has_device() function for such tests instead. Message-Id: <20211220081054.151515-2-thuth@redhat.com> Signed-off-by:
Thomas Huth <thuth@redhat.com>
-
Thomas Huth authored
These filter tests need a NIC, no matter which one, so they use a common NIC by default. However, these common NIC models might not always have been compiled into the QEMU target binary, so assuming that a certain NIC is available is a bad idea. Since the exact type of NIC does not really matter for these tests, let's switch to "-nic" instead of "-netdev" so that QEMU can simply pick a default NIC for us. This way we can now run the tests on other targets that have a default machine with an on-board/default NIC, too. Signed-off-by:
Thomas Huth <thuth@redhat.com> Message-Id: <20211220103025.311759-1-thuth@redhat.com> Reviewed-by:
Zhang Chen <chen.zhang@intel.com> Signed-off-by:
Thomas Huth <thuth@redhat.com>
-
Thomas Huth authored
When running the qtests, there are currently a bunch of warnings about the deprecated sga device during the boot-serial-test. Switch to "-M graphics=off" to silence these warnings. Message-Id: <20211220164042.397028-1-thuth@redhat.com> Reviewed-by:
Philippe Mathieu-Daudé <philmd@redhat.com> Reviewed-by:
Richard Henderson <richard.henderson@linaro.org> Signed-off-by:
Thomas Huth <thuth@redhat.com>
-
- Dec 21, 2021
-
-
Marc-André Lureau authored
Cover basic display interface usage. More cases to be added to cover disconnections, multiple connections, corner cases. At this point, they would be better written in Rust or Python though. The proxy also covers reading the properties, since they are automatically loaded at creation. Signed-off-by:
Marc-André Lureau <marcandre.lureau@redhat.com> Acked-by:
Gerd Hoffmann <kraxel@redhat.com>
-
Marc-André Lureau authored
Signed-off-by:
Marc-André Lureau <marcandre.lureau@redhat.com> Acked-by:
Gerd Hoffmann <kraxel@redhat.com>
-
Marc-André Lureau authored
Although not used by the backend itself, use a common location for documentation and sharing purposes. Signed-off-by:
Marc-André Lureau <marcandre.lureau@redhat.com> Acked-by:
Gerd Hoffmann <kraxel@redhat.com>
-
- Dec 18, 2021
-
-
Philippe Mathieu-Daudé authored
Without the previous commit, this test triggers: $ make check-qtest-x86_64 [...] Running test qtest-x86_64/fuzz-megasas-test qemu-system-x86_64: softmmu/physmem.c:3229: address_space_unmap: Assertion `mr != NULL' failed. Broken pipe ERROR qtest-x86_64/fuzz-megasas-test - too few tests run (expected 2, got 1) Suggested-by:
Alexander Bulekov <alxndr@bu.edu> Signed-off-by:
Philippe Mathieu-Daudé <philmd@redhat.com> Reviewed-by:
Darren Kenny <darren.kenny@oracle.com> Message-Id: <20211119201141.532377-3-philmd@redhat.com> Signed-off-by:
Paolo Bonzini <pbonzini@redhat.com>
-
Paolo Bonzini authored
The test was disabled when CONFIG_EPOLL_CREATE1 was moved out of config-host.mak. Fix the condition. Signed-off-by:
Paolo Bonzini <pbonzini@redhat.com>
-
Paolo Bonzini authored
The only difference between the two, as far as either configure or Meson are concerned, is the default endianness of the compiler. For tests/tcg, specify the endianness explicitly on the command line; for configure, do the same so that it is possible to have --cpu=ppc64le on a bigendian system or vice versa. Apart from this, cpu=ppc64le can be normalized to ppc64 also in configure and not just in the meson cross file. Reviewed-by:
Philippe Mathieu-Daudé <philmd@redhat.com> Reviewed-by:
Richard Henderson <richard.henderson@linaro.org> Signed-off-by:
Paolo Bonzini <pbonzini@redhat.com>
-
- Dec 17, 2021
-
-
Daniel Henrique Barboza authored
This test, if enabled by hand, was failing when the ivhsmem device was being declared as DEVICE_NATIVE_ENDIAN with the following error: /ppc64/ivshmem/pair: OK /ppc64/ivshmem/server: ** ERROR:/home/danielhb/qemu/tests/qtest/ivshmem-test.c:367:test_ivshmem_server: assertion failed (ret != 0): (0 != 0) Aborted After the endianness change done in the previous patch, we can verify in both a a Power 9 little-endian host and in a Power 8 big-endian host that this test is now passing: $ QTEST_QEMU_BINARY=./ppc64-softmmu/qemu-system-ppc64 ./tests/qtest/ivshmem-test -m slow /ppc64/ivshmem/single: OK /ppc64/ivshmem/hotplug: OK /ppc64/ivshmem/memdev: OK /ppc64/ivshmem/pair: OK /ppc64/ivshmem/server: OK Let's keep it that way by officially enabling it for ppc64. Acked-by:
Thomas Huth <thuth@redhat.com> Signed-off-by:
Daniel Henrique Barboza <danielhb413@gmail.com> Reviewed-by:
Philippe Mathieu-Daudé <philmd@redhat.com> Message-Id: <20211124092948.335389-3-danielhb413@gmail.com> Signed-off-by:
Cédric Le Goater <clg@kaod.org>
-