Skip to content

perf(qemu): improve boot time for amd64 guest on arm64 host

Luke Hackwell requested to merge qemu-config-optimisation into main

To test this I compared the time to build //qemu:os-release-amd64 (with dependencies cached) in the e2e tests with different configs:

config time (seconds)
no changes 424
-smp 2 390
-smp 4 379
-smp 8 387
-machine q35 367
-machine q35 -smp 4 370
  • 4 seems to be the sweet spot for the -smp value when no other changes are made.
  • The improvement of changing the machine to q35 was greater than the improvement of using -smp.
  • Using -smp seemed to have no effect when q35 was used.

I chose to keep -smp 4 in the config, as it may have some benefits when running other programs on the device other than booting.

Other than these options, I couldn't find anything else that might improve performance. It's hard to find information regarding this host-guest configuration as it seems to be rare.

Closes #30 (closed)

Edited by Alex Tercete

Merge request reports