From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from [140.186.70.92] (port=50576 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PGXV5-00032Y-ME for qemu-devel@nongnu.org; Thu, 11 Nov 2010 08:47:40 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PGXV4-00033m-Ii for qemu-devel@nongnu.org; Thu, 11 Nov 2010 08:47:39 -0500 Received: from mtagate4.uk.ibm.com ([194.196.100.164]:53822) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PGXV4-00032F-BR for qemu-devel@nongnu.org; Thu, 11 Nov 2010 08:47:38 -0500 Received: from d06nrmr1307.portsmouth.uk.ibm.com (d06nrmr1307.portsmouth.uk.ibm.com [9.149.38.129]) by mtagate4.uk.ibm.com (8.13.1/8.13.1) with ESMTP id oABDlZDW002824 for ; Thu, 11 Nov 2010 13:47:35 GMT Received: from d06av01.portsmouth.uk.ibm.com (d06av01.portsmouth.uk.ibm.com [9.149.37.212]) by d06nrmr1307.portsmouth.uk.ibm.com (8.13.8/8.13.8/NCO v10.0) with ESMTP id oABDlYDU3428556 for ; Thu, 11 Nov 2010 13:47:34 GMT Received: from d06av01.portsmouth.uk.ibm.com (loopback [127.0.0.1]) by d06av01.portsmouth.uk.ibm.com (8.14.4/8.13.1/NCO v10.0 AVout) with ESMTP id oABDlYr2015814 for ; Thu, 11 Nov 2010 06:47:35 -0700 From: Stefan Hajnoczi Date: Thu, 11 Nov 2010 13:47:19 +0000 Message-Id: <1289483242-6069-1-git-send-email-stefanha@linux.vnet.ibm.com> Subject: [Qemu-devel] [PATCH v2 0/3] virtio: Use ioeventfd for virtqueue notify List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: kvm@vger.kernel.org, "Michael S. Tsirkin" This is a rewrite of the virtio-ioeventfd patchset to work at the virtio-pci.c level instead of virtio.c. This results in better integration with the host/guest notifier code and makes the code simpler (no more state machine). Virtqueue notify is currently handled synchronously in userspace virtio. This prevents the vcpu from executing guest code while hardware emulation code handles the notify. On systems that support KVM, the ioeventfd mechanism can be used to make virtqueue notify a lightweight exit by deferring hardware emulation to the iothread and allowing the VM to continue execution. This model is similar to how vhost receives virtqueue notifies. The result of this change is improved performance for userspace virtio devices. Virtio-blk throughput increases especially for multithreaded scenarios and virtio-net transmit throughput increases substantially. Now that this code is in virtio-pci.c it is possible to explicitly enable devices for which virtio-ioeventfd should be used. Only virtio-blk and virtio-net are enabled at this time.