Sufficient L2 cache can noticeably improve the performance when using large images with frequent I/O. Previously, unless 'cache-size' was specified and was large enough, the L2 cache was set to a certain size without taking the virtual image size into account. Now, the L2 cache assignment is aware of the virtual size of the image, and will cover the entire image, unless the cache size needed for that is larger than a certain maximum. This maximum is set to 1 MB by default (enough to cover an 8 GB image with the default cluster size) but can be increased or decreased using the 'l2-cache-size' option. This option was previously documented as the *maximum* L2 cache size, and this patch makes it behave as such, instead of as a constant size. Also, the existing option 'cache-size' can limit the sum of both L2 and refcount caches, as previously. Signed-off-by: Leonid Bloch <lbloch@janustech.com> Reviewed-by: Alberto Garcia <berto@igalia.com> Reviewed-by: Kevin Wolf <kwolf@redhat.com> Signed-off-by: Kevin Wolf <kwolf@redhat.com>
51 lines
2.4 KiB
Plaintext
51 lines
2.4 KiB
Plaintext
QA output created by 137
|
|
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
|
|
=== Try setting valid values for all options ===
|
|
|
|
wrote 33554432/33554432 bytes at offset 0
|
|
32 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
|
|
read 33554432/33554432 bytes at offset 0
|
|
32 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
|
|
discard 33554432/33554432 bytes at offset 0
|
|
32 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
|
|
wrote 33554432/33554432 bytes at offset 0
|
|
32 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
|
|
read 33554432/33554432 bytes at offset 0
|
|
32 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
|
|
|
|
=== Try setting some invalid values ===
|
|
|
|
Parameter 'lazy-refcounts' expects 'on' or 'off'
|
|
cache-size, l2-cache-size and refcount-cache-size may not be set at the same time
|
|
l2-cache-size may not exceed cache-size
|
|
refcount-cache-size may not exceed cache-size
|
|
L2 cache entry size must be a power of two between 512 and the cluster size (65536)
|
|
L2 cache entry size must be a power of two between 512 and the cluster size (65536)
|
|
Refcount cache size too big
|
|
Conflicting values for qcow2 options 'overlap-check' ('constant') and 'overlap-check.template' ('all')
|
|
Unsupported value 'blubb' for qcow2 option 'overlap-check'. Allowed are any of the following: none, constant, cached, all
|
|
Unsupported value 'blubb' for qcow2 option 'overlap-check'. Allowed are any of the following: none, constant, cached, all
|
|
Cache clean interval too big
|
|
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=36028797018963968
|
|
L2 cache size too big
|
|
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
|
|
|
|
=== Test transaction semantics ===
|
|
|
|
Unsupported value 'blubb' for qcow2 option 'overlap-check'. Allowed are any of the following: none, constant, cached, all
|
|
wrote 512/512 bytes at offset 0
|
|
512 bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
|
|
./common.rc: Killed ( if [ "${VALGRIND_QEMU}" == "y" ]; then
|
|
exec valgrind --log-file="${VALGRIND_LOGFILE}" --error-exitcode=99 "$QEMU_IO_PROG" $QEMU_IO_ARGS "$@";
|
|
else
|
|
exec "$QEMU_IO_PROG" $QEMU_IO_ARGS "$@";
|
|
fi )
|
|
incompatible_features 0x0
|
|
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
|
|
wrote 65536/65536 bytes at offset 0
|
|
64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
|
|
Parameter 'lazy-refcounts' expects 'on' or 'off'
|
|
qcow2: Marking image as corrupt: Preventing invalid write on metadata (overlaps with qcow2_header); further corruption events will be suppressed
|
|
write failed: Input/output error
|
|
*** done
|