Received: from eggs.gnu.org ([2001:4830:134:3::10]:42934) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aLYse-0005uM-R2 for qemu-devel@nongnu.org; Tue, 19 Jan 2016 11:11:41 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aLYsa-0002Nd-Lx for qemu-devel@nongnu.org; Tue, 19 Jan 2016 11:11:40 -0500 Received: from e06smtp14.uk.ibm.com ([195.75.94.110]:54878) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aLYsa-0002N7-C3 for qemu-devel@nongnu.org; Tue, 19 Jan 2016 11:11:36 -0500 Received: from localhost by e06smtp14.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Tue, 19 Jan 2016 16:11:35 -0000 Received: from b06cxnps3075.portsmouth.uk.ibm.com (d06relay10.portsmouth.uk.ibm.com [9.149.109.195]) by d06dlp01.portsmouth.uk.ibm.com (Postfix) with ESMTP id 6F59A17D8042 for ; Tue, 19 Jan 2016 16:11:37 +0000 (GMT) Received: from d06av05.portsmouth.uk.ibm.com (d06av05.portsmouth.uk.ibm.com [9.149.37.229]) by b06cxnps3075.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id u0JGBWPD65929248 for ; Tue, 19 Jan 2016 16:11:32 GMT Received: from d06av05.portsmouth.uk.ibm.com (localhost [127.0.0.1]) by d06av05.portsmouth.uk.ibm.com (8.14.4/8.14.4/NCO v10.0 AVout) with ESMTP id u0JGBWIX030934 for ; Tue, 19 Jan 2016 09:11:32 -0700 Date: Tue, 19 Jan 2016 17:11:29 +0100 From: Cornelia Huck Message-ID: <20160119171129.25365a38.cornelia.huck@de.ibm.com> In-Reply-To: <1452861718-25806-9-git-send-email-pbonzini@redhat.com> References: <1452861718-25806-1-git-send-email-pbonzini@redhat.com> <1452861718-25806-9-git-send-email-pbonzini@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH 08/10] virtio: cache used_idx in a VirtQueue field List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Paolo Bonzini Cc: qemu-devel@nongnu.org, Vincenzo Maffione , mst@redhat.com On Fri, 15 Jan 2016 13:41:56 +0100 Paolo Bonzini wrote: > From: Vincenzo Maffione > > Accessing used_idx in the VQ requires an expensive access to > guest physical memory. Before this patch, 3 accesses are normally > done for each pop/push/notify call. However, since the used_idx is > only written by us, we can track it in our internal data structure. > > Signed-off-by: Vincenzo Maffione > Message-Id: <3d062ec54e9a7bf9fb325c1fd693564951f2b319.1450218353.git.v.maffione@gmail.com> > Signed-off-by: Paolo Bonzini > --- > hw/virtio/virtio.c | 12 +++++++++--- > 1 file changed, 9 insertions(+), 3 deletions(-) Reviewed-by: Cornelia Huck