[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH v5 0/2] block: enforce minimal 4096 alignment in
From: |
Dmitry Monakhov |
Subject: |
Re: [Qemu-devel] [PATCH v5 0/2] block: enforce minimal 4096 alignment in qemu_blockalign |
Date: |
Mon, 01 Jun 2015 14:57:00 +0300 |
User-agent: |
Notmuch/0.18.1 (http://notmuchmail.org) Emacs/24.4.1 (x86_64-pc-linux-gnu) |
<#secure method=pgpmime mode=sign>
Paolo Bonzini <address@hidden> writes:
> On 01/06/2015 13:16, Dmitry Monakhov wrote:
>> 259,0 31 385 0.719283423 10729 Q WS 29376775 + 248 [qemu-io]
>> 259,0 31 388 0.719287600 10729 Q WS 29377023 + 8 [qemu-io]
>> 259,0 31 391 0.719315193 10729 Q WS 29377031 + 248 [qemu-io]
>> 259,0 31 394 0.719319179 10729 Q WS 29377279 + 8 [qemu-io]
>
> Compared to the old one:
>
>> 9,0 11 1 0.000000000 11151 Q WS 312737792 + 1023 [qemu-img]
>> 9,0 11 2 0.000007938 11151 Q WS 312738815 + 8 [qemu-img]
>> 9,0 11 3 0.000030735 11151 Q WS 312738823 + 1016 [qemu-img]
>> 9,0 11 4 0.000032482 11151 Q WS 312739839 + 8 [qemu-img]
>> 9,0 11 5 0.000041379 11151 Q WS 312739847 + 1016 [qemu-img]
>> 9,0 11 6 0.000042818 11151 Q WS 312740863 + 8 [qemu-img]
>> 9,0 11 7 0.000051236 11151 Q WS 312740871 + 1017 [qemu-img]
>
> I suspect the difference is that my patch avoids RMW operations on disks
> that have 512-byte logical blocks and 4K physical blocks.
Probably. I've checked bio/request submission path for my nvme device and it is
appeared that merge is merges are disabled for that device.
/sys/block/nvme0n1/queue/nomerges -> 2 (QUEUE_FLAG_NOMERGES)
so we follow this trace
->blk_mq_make_request(bio)
if(!blk_mq_merge_queue_io)
blk_mq_run_hw_queue(data.hctx, !is_sync || is_flush_fua);
So the only thing we can in order to improve performance is to is to
modify fs/direct-io.c -> bio submission path by constructing bios with maximum
size.
>
> Paolo