|
From: | Peter Lieven |
Subject: | Re: [Qemu-block] virtio-scsi and request splitting |
Date: | Thu, 1 Jun 2017 16:11:37 +0200 |
User-agent: | Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.5.1 |
Am 01.06.2017 um 15:46 schrieb Paolo Bonzini:
On 01/06/2017 15:42, Peter Lieven wrote:Any idea whats the cause of this?It may depend on memory fragmentation.This sounds like nothing that can be influenced or changed? I forgot to mention, if I specify bs=512k the requests go through also with virtio-scsiCan you repeat it many times, perhaps with different amount of memory in the VMs, and trace the number of buffers. I'll send this patch shortly. diff --git a/hw/virtio/trace-events b/hw/virtio/trace-events index 1f7a7c1ae1..e24d8fa997 100644 --- a/hw/virtio/trace-events +++ b/hw/virtio/trace-events @@ -1,6 +1,7 @@ # See docs/tracing.txt for syntax documentation.# hw/virtio/virtio.c+virtqueue_alloc_element(void *elem, size_t sz, unsigned in_num, unsigned out_num) "elem %p size %zd in_num %u out_num %u" virtqueue_fill(void *vq, const void *elem, unsigned int len, unsigned int idx) "vq %p elem %p len %u idx %u" virtqueue_flush(void *vq, unsigned int count) "vq %p count %u" virtqueue_pop(void *vq, void *elem, unsigned int in_num, unsigned int out_num) "vq %p elem %p in_num %u out_num %u" diff --git a/hw/virtio/virtio.c b/hw/virtio/virtio.c index 890b4d7eb7..286446b261 100644 --- a/hw/virtio/virtio.c +++ b/hw/virtio/virtio.c @@ -816,6 +816,7 @@ static void *virtqueue_alloc_element(size_t sz, unsigned out_num, unsigned in_nuassert(sz >= sizeof(VirtQueueElement));elem = g_malloc(out_sg_end); + trace_virtqueue_alloc_element(elem, sz, in_num, out_num); elem->out_num = out_num; elem->in_num = in_num; elem->in_addr = (void *)elem + in_addr_ofs;
Where shall I send the traces? The output for the dd phase looks sth like this. Is this correct? virtqueue_alloc_element 30498.707 pid=28286 elem=0x560dcca24200 sz=0xf0 in_num=0x1 out_num=0x36 virtqueue_alloc_element 7.558 pid=28286 elem=0x560dcca22680 sz=0xf0 in_num=0x1 out_num=0x1a virtqueue_alloc_element 1.410 pid=28286 elem=0x560dcdf916c0 sz=0xf0 in_num=0x1 out_num=0x2 virtqueue_alloc_element 27545.182 pid=28286 elem=0x560dcca24200 sz=0xf0 in_num=0x1 out_num=0x36 virtqueue_alloc_element 7.727 pid=28286 elem=0x560dcca22680 sz=0xf0 in_num=0x1 out_num=0x1a virtqueue_alloc_element 1.381 pid=28286 elem=0x560dcca27f20 sz=0xf0 in_num=0x1 out_num=0x2 virtqueue_alloc_element 30835.506 pid=28286 elem=0x560dcca24200 sz=0xf0 in_num=0x1 out_num=0x36 virtqueue_alloc_element 8.139 pid=28286 elem=0x560dcca22680 sz=0xf0 in_num=0x1 out_num=0x1a virtqueue_alloc_element 1.444 pid=28286 elem=0x560dcca30440 sz=0xf0 in_num=0x1 out_num=0x2 virtqueue_alloc_element 31896.240 pid=28286 elem=0x560dcca24200 sz=0xf0 in_num=0x1 out_num=0x36 virtqueue_alloc_element 5.191 pid=28286 elem=0x560dcca22680 sz=0xf0 in_num=0x1 out_num=0x1a virtqueue_alloc_element 1.365 pid=28286 elem=0x560dcdf916c0 sz=0xf0 in_num=0x1 out_num=0x2 virtqueue_alloc_element 29935.484 pid=28286 elem=0x560dcca24200 sz=0xf0 in_num=0x1 out_num=0x36 virtqueue_alloc_element 7.560 pid=28286 elem=0x560dcca22680 sz=0xf0 in_num=0x1 out_num=0x1a virtqueue_alloc_element 1.446 pid=28286 elem=0x560dcca27f20 sz=0xf0 in_num=0x1 out_num=0x2 virtqueue_alloc_element 28896.755 pid=28286 elem=0x560dcca24200 sz=0xf0 in_num=0x1 out_num=0x36 virtqueue_alloc_element 7.414 pid=28286 elem=0x560dcca22680 sz=0xf0 in_num=0x1 out_num=0x1a virtqueue_alloc_element 1.426 pid=28286 elem=0x560dcca30440 sz=0xf0 in_num=0x1 out_num=0x2 virtqueue_alloc_element 27605.770 pid=28286 elem=0x560dcca24200 sz=0xf0 in_num=0x1 out_num=0x36 virtqueue_alloc_element 7.824 pid=28286 elem=0x560dcca22680 sz=0xf0 in_num=0x1 out_num=0x1a virtqueue_alloc_element 1.679 pid=28286 elem=0x560dcdf916c0 sz=0xf0 in_num=0x1 out_num=0x2 virtqueue_alloc_element 28840.024 pid=28286 elem=0x560dcca24200 sz=0xf0 in_num=0x1 out_num=0x36 virtqueue_alloc_element 5.522 pid=28286 elem=0x560dcca22680 sz=0xf0 in_num=0x1 out_num=0x1a virtqueue_alloc_element 1.350 pid=28286 elem=0x560dcca27f20 sz=0xf0 in_num=0x1 out_num=0x2 virtqueue_alloc_element 29710.823 pid=28286 elem=0x560dcca24200 sz=0xf0 in_num=0x1 out_num=0x36 virtqueue_alloc_element 5.642 pid=28286 elem=0x560dcca22680 sz=0xf0 in_num=0x1 out_num=0x1a virtqueue_alloc_element 1.379 pid=28286 elem=0x560dcca30440 sz=0xf0 in_num=0x1 out_num=0x2 virtqueue_alloc_element 31220.369 pid=28286 elem=0x560dcca24200 sz=0xf0 in_num=0x1 out_num=0x36 virtqueue_alloc_element 7.566 pid=28286 elem=0x560dcca22680 sz=0xf0 in_num=0x1 out_num=0x1a virtqueue_alloc_element 1.521 pid=28286 elem=0x560dcdf916c0 sz=0xf0 in_num=0x1 out_num=0x2 virtqueue_alloc_element 29681.131 pid=28286 elem=0x560dcca24200 sz=0xf0 in_num=0x1 out_num=0x36 virtqueue_alloc_element 7.943 pid=28286 elem=0x560dcca22680 sz=0xf0 in_num=0x1 out_num=0x1a virtqueue_alloc_element 1.435 pid=28286 elem=0x560dcca27f20 sz=0xf0 in_num=0x1 out_num=0x2 virtqueue_alloc_element 29668.865 pid=28286 elem=0x560dcca24200 sz=0xf0 in_num=0x1 out_num=0x36 virtqueue_alloc_element 7.738 pid=28286 elem=0x560dcca22680 sz=0xf0 in_num=0x1 out_num=0x1a virtqueue_alloc_element 1.421 pid=28286 elem=0x560dcca30440 sz=0xf0 in_num=0x1 out_num=0x2 virtqueue_alloc_element 30921.678 pid=28286 elem=0x560dcca24200 sz=0xf0 in_num=0x1 out_num=0x36 virtqueue_alloc_element 5.479 pid=28286 elem=0x560dcca22680 sz=0xf0 in_num=0x1 out_num=0x1a virtqueue_alloc_element 1.418 pid=28286 elem=0x560dcdf916c0 sz=0xf0 in_num=0x1 out_num=0x2 virtqueue_alloc_element 31445.380 pid=28286 elem=0x560dcca24200 sz=0xf0 in_num=0x1 out_num=0x36 virtqueue_alloc_element 7.624 pid=28286 elem=0x560dcca22680 sz=0xf0 in_num=0x1 out_num=0x1a virtqueue_alloc_element 1.380 pid=28286 elem=0x560dcca27f20 sz=0xf0 in_num=0x1 out_num=0x2 virtqueue_alloc_element 31299.041 pid=28286 elem=0x560dcca24200 sz=0xf0 in_num=0x1 out_num=0x36 virtqueue_alloc_element 5.837 pid=28286 elem=0x560dcca22680 sz=0xf0 in_num=0x1 out_num=0x1a virtqueue_alloc_element 1.367 pid=28286 elem=0x560dcca30440 sz=0xf0 in_num=0x1 out_num=0x2 virtqueue_alloc_element 31397.147 pid=28286 elem=0x560dcca24200 sz=0xf0 in_num=0x1 out_num=0x36 virtqueue_alloc_element 7.477 pid=28286 elem=0x560dcca22680 sz=0xf0 in_num=0x1 out_num=0x1a virtqueue_alloc_element 1.452 pid=28286 elem=0x560dcdf916c0 sz=0xf0 in_num=0x1 out_num=0x2 virtqueue_alloc_element 56200.961 pid=28286 elem=0x560dcca24200 sz=0xf0 in_num=0x1 out_num=0x36 virtqueue_alloc_element 7.674 pid=28286 elem=0x560dcca22680 sz=0xf0 in_num=0x1 out_num=0x1a virtqueue_alloc_element 1.389 pid=28286 elem=0x560dcca27f20 sz=0xf0 in_num=0x1 out_num=0x2 BR, Peter
[Prev in Thread] | Current Thread | [Next in Thread] |