Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752257AbdHPORO (ORCPT ); Wed, 16 Aug 2017 10:17:14 -0400 Received: from mx1.redhat.com ([209.132.183.28]:39635 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751635AbdHPORM (ORCPT ); Wed, 16 Aug 2017 10:17:12 -0400 DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com AEEDE7BE43 Authentication-Results: ext-mx01.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=redhat.com Authentication-Results: ext-mx01.extmail.prod.ext.phx2.redhat.com; spf=fail smtp.mailfrom=pbonzini@redhat.com Date: Wed, 16 Aug 2017 10:17:10 -0400 (EDT) From: Paolo Bonzini To: "Michael S. Tsirkin" Cc: Radim =?utf-8?B?S3LEjW3DocWZ?= , linux-kernel@vger.kernel.org, kvm@vger.kernel.org, stable@vger.kernel.org Message-ID: <1530586086.975916.1502893030374.JavaMail.zimbra@redhat.com> In-Reply-To: <20170816170329-mutt-send-email-mst@kernel.org> References: <20170816112249.28939-1-pbonzini@redhat.com> <20170816120702.GC6408@flask> <49976600-3d63-5ac4-cc13-1465b0ecf9f5@redhat.com> <20170816170329-mutt-send-email-mst@kernel.org> Subject: Re: [PATCH] kvm: x86: disable KVM_FAST_MMIO_BUS MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Originating-IP: [94.39.192.75, 10.4.196.19, 10.4.195.12] Thread-Topic: x86: disable KVM_FAST_MMIO_BUS Thread-Index: 156U5AyeCFCm68VwKT8ok45/4GVoeg== X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.25]); Wed, 16 Aug 2017 14:17:12 +0000 (UTC) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 595 Lines: 19 > We actually know what to expect (a write) so we could maybe > optimize this some more with a dedicated function just for this. We don't know the addressing mode, the size or the source (immediate vs. register), so no. KVM is already doing a single translation and read no matter how long the instruction (unless it cross page boundaries). Paolo > > > > However, the eventfd is written before decoding, while full emulation > > would write it after. So while VCPU thread latency is worse compared to > > skip_emulated_instruction, latency to the iothread remains small. > > > > Paolo >