From mboxrd@z Thu Jan 1 00:00:00 1970 From: Christian Borntraeger Subject: Re: [PATCH v2] KVM: halt-polling: poll if emulated lapic timer will fire soon Date: Thu, 19 May 2016 17:03:37 +0200 Message-ID: <573DD5C9.2000108@de.ibm.com> References: <1463664426-2991-1-git-send-email-wanpeng.li@hotmail.com> <19abf5c8-7016-45af-f0e6-3bdd161ffb38@redhat.com> <573DD312.4060001@de.ibm.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Cc: Wanpeng Li , =?UTF-8?B?UmFkaW0gS3LEjW3DocWZ?= , David Matlack To: Paolo Bonzini , Wanpeng Li , linux-kernel@vger.kernel.org, kvm@vger.kernel.org Return-path: In-Reply-To: Sender: linux-kernel-owner@vger.kernel.org List-Id: kvm.vger.kernel.org On 05/19/2016 04:56 PM, Paolo Bonzini wrote: > > > On 19/05/2016 16:52, Christian Borntraeger wrote: >>>> Would this work too and be simpler? >> Hmm, your patch does only fiddle with the grow/shrink logic (which might >> be a good idea independently of this change), but the original patch >> actually takes into account that we have a guaranteed maximum time by a >> wakeup timer - IOW we know exactly what the maximum poll time is. >> > > Yes, it's different. The question is whether a 10us poll (40,000 clock > cycles) has an impact even if it's sometimes wrong. Valid question. As I said, this change might be something good independent from the original patch. (it might make it unnecessary, though) On the other hand I can handle ~30 guest entry/exit cycles of a simple exit like diag9c. Needs measurement.