[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v2 3/3] qcow2: handle_dependencies(): relax conflict detectio
From: |
Eric Blake |
Subject: |
Re: [PATCH v2 3/3] qcow2: handle_dependencies(): relax conflict detection |
Date: |
Wed, 25 Aug 2021 09:16:14 -0500 |
User-agent: |
NeoMutt/20210205-739-420e15 |
On Tue, Aug 24, 2021 at 01:15:17PM +0300, Vladimir Sementsov-Ogievskiy wrote:
> There is no conflict and no dependency if we have parallel writes to
> different subclusters of one cluster when the cluster itself is already
> allocated. So, relax extra dependency.
>
...
> So small writes are more independent now and that helps to keep deeper
> io queue which improves performance.
>
> 271 iotest output becomes racy for three allocation in one cluster.
> Second and third writes may finish in different order. Second and
> third requests don't depend on each other any more. Still they both
> depend on first request anyway. Filter out second and third write
> offsets to cover both possible outputs.
>
> Signed-off-by: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
> ---
> block/qcow2-cluster.c | 11 +++++++++++
> tests/qemu-iotests/271 | 5 ++++-
> tests/qemu-iotests/271.out | 4 ++--
> 3 files changed, 17 insertions(+), 3 deletions(-)
>
> +++ b/tests/qemu-iotests/271
> @@ -893,7 +893,10 @@ EOF
> }
>
> _make_test_img -o extended_l2=on 1M
> -_concurrent_io | $QEMU_IO | _filter_qemu_io
> +# Second an third writes in _concurrent_io() are independent and may finish
> in
and
> +# different order. So, filter offset out to match both possible variants.
> +_concurrent_io | $QEMU_IO | _filter_qemu_io | \
> + $SED -e 's/\(20480\|40960\)/OFFSET/'
> _concurrent_verify | $QEMU_IO | _filter_qemu_io
>
Reviewed-by: Eric Blake <eblake@redhat.com>
--
Eric Blake, Principal Software Engineer
Red Hat, Inc. +1-919-301-3266
Virtualization: qemu.org | libvirt.org