On 16/12/2014 14:10, Kevin Wolf wrote: > Am 16.12.2014 um 12:28 hat Paolo Bonzini geschrieben: >> >> >> On 16/12/2014 12:07, Kevin Wolf wrote: >>> Am 11.12.2014 um 14:52 hat Paolo Bonzini geschrieben: >>>> Keep a queue of requests that were not submitted; pass them to >>>> the kernel when a completion is reported, unless the queue is >>>> plugged. >>>> >>>> The array of iocbs is rebuilt every time from scratch. This >>>> avoids keeping the iocbs array and list synchronized. >>>> >>>> Signed-off-by: Paolo Bonzini <pbonz...@redhat.com> >>> >>> Just found out that in qemu-img bench, this patch seems to cost about >>> 5-8% for me. >> >> What execution? Queue depth=1? > > My usual one: > > $ ./qemu-img bench -t none -c 10000000 -n /dev/loop0 > Sending 10000000 requests, 4096 bytes each, 64 in parallel
I could reproduce this very well on a random OS image that I had around. This is raw over XFS over dm-crypt, and the image is about 75% sparse (8.2G used over 35G). I only get 1-2%, but still it's visible. However I can hardly reproduce it when using a partition directly: old new mean 9.9565 9.9636 (+0.07%) stddev 0.0405 0.0537 min 9.871 9.867 median 9.973 9.971 max 10.01 10.053 count 20 20 I haven't tried removing layers (e.g. fully-allocated XFS image without dm-crypt). Paolo