diff options
Diffstat (limited to 'results/classifier/accel-gemma3:12b/kvm/498417')
| -rw-r--r-- | results/classifier/accel-gemma3:12b/kvm/498417 | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/results/classifier/accel-gemma3:12b/kvm/498417 b/results/classifier/accel-gemma3:12b/kvm/498417 new file mode 100644 index 000000000..586c5db61 --- /dev/null +++ b/results/classifier/accel-gemma3:12b/kvm/498417 @@ -0,0 +1,15 @@ + +cache=writeback on disk image doesn't do write-back + +I noticed that qemu seems to have poor disk performance. Here's a test that has miserable performance but which should be really fast: + +- Configure qemu to use the disk image with cache=writeback +- Configure a 2GiB Linux VM on an 8GiB Linux host +- In the VM, write a 4GiB file (dd if=/dev/zero of=/tmp/x bs=4K count=1M) +- In the VM, read it back (dd if=/tmp/x of=/dev/null bs=4K count=1M) + +With writeback, the whole file should end up in the host pagecache. So when I read it back, there should be no I/O to the real disk, and it should be really fast. Instead, I see disk activity through the duration of the test, and the performance is roughly the native hard disk throughput (somewhat slower). + +I'm using version 0.11.1, and this is my command line: + +qemu-system-x86_64 -drive cache=writeback,index=0,media=disk,file=ubuntu.img -k en-us -m 2048 -smp 2 -vnc :3100 -usbdevice tablet -enable-kvm & \ No newline at end of file |