qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] Following up questions related to QEMU and I/O Thread


From: Wei Li
Subject: Re: [Qemu-devel] Following up questions related to QEMU and I/O Thread
Date: Mon, 04 Mar 2019 09:33:26 -0800
User-agent: Microsoft-MacOutlook/10.15.0.190115

Hi Stefan and all,

 

I spent some time on getting familiar with QEMU and relevant concepts. My 
project is using QEMU 2.9 with virtio-scsi backend, and I am exploring proper 
way to improve the IOPS of my project.

 

Thanks @Stefan for the response and advices!

 

Could you please help review and clarify following questions:
While @Stefan mentioned about additional iothread object support of virtio-blk, 
Is the feature also supported by virtio-scsi? I am trying to exploring the perf 
multiple IO threads / per VM via followings:
QMP setup example to create 2 io threads in QEMU, one io thread per device:

(QEMU) object-add qom-type=iothread id=iothread0

(QEMU) object-add qom-type=iothread id=iothread1

 

(QEMU) device_add driver=virtio-scsi-pci id=test0 iothread=iothread0

(QEMU) device_add driver=virtio-scsi-pci id=test1 iothread=iothread1

 

(QEMU) device_add driver=scsi-block drive=none0 id=v0 bus=test0.0

(QEMU) device_add driver=scsi-block drive=none1 id=v1 bus=test1.0
You mentioned about the multi-queue devices feature, it seems like the 
multi-queue feature will help improve the IOPS of  single Device. Could you 
please provide more details?
What’s the current plan of support multi-queue device? Which release will 
include the support or it has already been included in any existing release 
newer than 2.9?
Is there any feature branch which I would get more details about the code and 
in progress status?
In addition, Someone posted related to multi-queue 
https://marc.info/?l=linux-virtualization&m=135583400026151&w=2, but it only 
measure the bandwidth, do we have any perf result about IOPS improvement of 
Multi-Queue approach?
 

Thanks again,

Wei

 

 

On 2/18/19, 2:24 AM, "Stefan Hajnoczi" <address@hidden> wrote:

 

    On Thu, Feb 14, 2019 at 08:21:30AM -0800, Wei Li wrote:

    > I learnt that QEMU iothread architecture has one QEMU thread per vCPU and 
a dedicated event loop thread which is iothread, and I want to better 
understand whether there is any specific reason to have a single iothead 
instead of multiple iothreads?

    > Given that single iothread becomes a performance bottleneck in my 
project, if there any proper way to support multiple iothreads? E.g. have one 
iothread per volume attachment instead of single iothread per host?  But I am 
not quite sure whether it is feasible or not. Please let me know if you have 
any advices.

    

    Hi,

    Please send general questions to address@hidden and CC me in the

    future.  That way others can participate in the discussion and it will

    be archived so someone searching for the same question will find the

    answer in the future.

    

    QEMU supports additional IOThread objects:

    

      -object iothread,id=iothread0

      -device virtio-blk-pci,iothread=iothread0,drive=drive0

    

    This virtio-blk device will perform device emulation and I/O in

    iothread0 instead of the main loop thread.

    

    Currently only 1:1 device<->IOThread association is possible.  In the

    future 1:N should be possible and will allow multi-queue devices to

    achieve better performance.

    

    Stefan

 



reply via email to

[Prev in Thread] Current Thread [Next in Thread]