aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAleksandr Nogikh <nogikh@google.com>2023-06-27 19:31:40 +0200
committerAleksandr Nogikh <wp32pw@gmail.com>2023-06-28 11:22:09 +0200
commit8064cb02abe85f2c6b7c5ae84cdeacef133e6474 (patch)
tree4640e5ac4cf1365c8908f83811c1517a55a24b25
parent4cd5bb25a2752a9a5b25597d1da34656681f07a6 (diff)
vm: speed up arm/arm64 emulation
The `-accel tcg,thread=multi` option speeds up boot by ~25%. Execution speed shoud also increase.
-rw-r--r--vm/qemu/qemu.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/vm/qemu/qemu.go b/vm/qemu/qemu.go
index bb7ed220d..d32d58143 100644
--- a/vm/qemu/qemu.go
+++ b/vm/qemu/qemu.go
@@ -147,7 +147,7 @@ var archConfigs = map[string]*archConfig{
},
"linux/arm64": {
Qemu: "qemu-system-aarch64",
- QemuArgs: "-machine virt,virtualization=on -cpu cortex-a57",
+ QemuArgs: "-machine virt,virtualization=on -cpu cortex-a57 -accel tcg,thread=multi",
NetDev: "virtio-net-pci",
RngDev: "virtio-rng-pci",
CmdLine: []string{
@@ -157,7 +157,7 @@ var archConfigs = map[string]*archConfig{
},
"linux/arm": {
Qemu: "qemu-system-arm",
- QemuArgs: "-machine vexpress-a15 -cpu max",
+ QemuArgs: "-machine vexpress-a15 -cpu max -accel tcg,thread=multi",
NetDev: "virtio-net-device",
RngDev: "virtio-rng-device",
UseNewQemuImageOptions: true,