tests/qtest: make migration-test massively faster
Get series with b4
b4 am [email protected]Versions newest first · linked by author and title
- v4 Latest10 patches 8 repliesIn review
- v39 patches 47 repliesSuperseded
- v26 patches 19 repliesSuperseded
Earlier versions · 1
| Version | Posted | Patches | Replies | Status |
|---|---|---|---|---|
| v1 | 2 patches | 7 replies | Superseded |
Patches in v4 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/10 | tests/qtest: add various qtest_qmp_assert_success() variantstests/ tests/ | +205 | 1 reply | |
| 2/10 | tests/qtest: add support for callback to receive QMP eventstests/ tests/ | +57 | 2 replies | |
| 3/10 | tests/qtest: get rid of 'qmp_command' helper in migration testtests/ tests/ tests/ | +15 | 1 reply | |
| 4/10 | tests/qtest: get rid of some 'qtest_qmp' usage in migration testtests/ tests/ | +21 | 0 replies | |
| 5/10 | tests/qtest: switch to using event callbacks for STOP eventtests/ tests/ tests/ | +15 | 0 replies | |
| 6/10 | tests/qtest: replace wait_command() with qtest_qmp_assert_successtests/ tests/ tests/ | +74 | 0 replies | |
| 7/10 | tests/qtest: capture RESUME events during migrationtests/ tests/ tests/ | +20 | 1 reply | |
| 8/10 | tests/qtest: distinguish src/dst migration VM stop/resume eventstests/ | +13 | 1 reply | |
| 9/10 | tests/qtest: make more migration pre-copy scenarios run non-livetests/ | +66 | 1 reply | |
| 10/10 | tests/qtest: massively speed up migration-testtests/ | +125 | 0 replies |
Reviews trailers per patch
9 of 10 patches have a Reviewed-by or Acked-by of their own; the series has one for all of them.
| Patch | Juan Quintela | Thomas Huth | Daniel P. Berrangé |
|---|---|---|---|
| Series | R-b | R-b | |
| 1/10 | R-b | R-b | |
| 2/10 | R-b | R-b | |
| 3/10 | R-b | R-b | |
| 4/10 | R-b | R-b | |
| 5/10 | R-b | A-b | |
| 6/10 | R-b | R-b | |
| 7/10 | R-b | ||
| 8/10 | R-b | ||
| 9/10 | R-b | T-b | |
| 10/10 |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes. Scroll the table sideways for all 3 reviewers.
Cover letter [PATCH v4 00/10] tests/qtest: make migration-test massively faster
This makes migration-test faster by observing that most of the pre-copy tests don't need to be doing a live migration. They get sufficient code coverage with the guest CPUs paused.
On my machine this cuts the overall execution time of migration-test from 13 minutes, down to 8 minutes, without sacrificing any noticeable code coverage.
Of the tests which do still run in live mode, some need to guarantee a certain number of iterions. This is achieved by running the 1 iteration with an incredibly small bandwidth and max downtime to prevent convergance, and watching query-migrate for the reported iteration to increment. This guarantees that all the tests take at least 30 seconds to run per iteration required.
Watching for the iteration counter to flip is inefficient and not actually needed, except on the final iteration before starting convergance. On this final iteration we merely need to prove that some amount of already transferred data has been made dirty again. This in turn will guarantee that a further iteration is required beyond the current one. This proof is easy to achieve by monitoring the values at two distinct addresses in guest RAM, and can cut the 30 second duration down to 1 second for one of the iterations.
After this this second optimization the runtime is reduced from 8 minutes, down to 1 minute 40 seconds, which is pretty decent given the amount of coverage we're getting.
Daniel P. Berrangé (10):
tests/qtest: add various qtest_qmp_assert_success() variants tests/qtest: add support for callback to receive QMP events tests/qtest: get rid of 'qmp_command' helper in migration test tests/qtest: get rid of some 'qtest_qmp' usage in migration test tests/qtest: switch to using event callbacks for STOP event tests/qtest: replace wait_command() with qtest_qmp_assert_success tests/qtest: capture RESUME events during migration tests/qtest: distinguish src/dst migration VM stop/resume events tests/qtest: make more migration pre-copy scenarios run non-live tests/qtest: massively speed up migration-test
tests/qtest/libqtest.c | 115 +++++++- tests/qtest/libqtest.h | 158 ++++++++++- tests/qtest/migration-helpers.c | 103 ++----- tests/qtest/migration-helpers.h | 16 +- tests/qtest/migration-test.c | 472 ++++++++++++++++++++------------ 5 files changed, 586 insertions(+), 278 deletions(-)
Signature · 1 line
2.40.1