From mboxrd@z Thu Jan 1 00:00:00 1970 From: Raghavendra K T Subject: Re: [PATCH 3/4] arm64: KVM: let other tasks run when hitting WFE Date: Mon, 22 Jul 2013 19:27:58 +0530 Message-ID: <51ED3A66.4050407@linux.vnet.ibm.com> References: <1374242035-13199-1-git-send-email-marc.zyngier@arm.com> <1374242035-13199-4-git-send-email-marc.zyngier@arm.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: Raghavendra KT , Marc Zyngier , "linux-arm-kernel@lists.infradead.org" , "kvm@vger.kernel.org" , "kvmarm@lists.cs.columbia.edu" , Catalin Marinas , Will Deacon To: Christoffer Dall Return-path: Received: from e23smtp06.au.ibm.com ([202.81.31.148]:32904 "EHLO e23smtp06.au.ibm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755497Ab3GVNum (ORCPT ); Mon, 22 Jul 2013 09:50:42 -0400 Received: from /spool/local by e23smtp06.au.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Mon, 22 Jul 2013 23:42:50 +1000 Received: from d23relay03.au.ibm.com (d23relay03.au.ibm.com [9.190.235.21]) by d23dlp02.au.ibm.com (Postfix) with ESMTP id CFDA02BB0069 for ; Mon, 22 Jul 2013 23:50:35 +1000 (EST) Received: from d23av01.au.ibm.com (d23av01.au.ibm.com [9.190.234.96]) by d23relay03.au.ibm.com (8.13.8/8.13.8/NCO v10.0) with ESMTP id r6MDoPd556819788 for ; Mon, 22 Jul 2013 23:50:25 +1000 Received: from d23av01.au.ibm.com (loopback [127.0.0.1]) by d23av01.au.ibm.com (8.14.4/8.13.1/NCO v10.0 AVout) with ESMTP id r6MDoTxw017338 for ; Mon, 22 Jul 2013 23:50:31 +1000 In-Reply-To: Sender: kvm-owner@vger.kernel.org List-ID: On 07/22/2013 06:21 PM, Christoffer Dall wrote: > On 22 July 2013 10:53, Raghavendra KT wrote: >> On Fri, Jul 19, 2013 at 7:23 PM, Marc Zyngier wrote: >>> So far, when a guest executes WFE (like when waiting for a spinlock >>> to become unlocked), we don't do a thing and let it run uninterrupted. >>> >>> Another option is to trap a blocking WFE and offer the opportunity >>> to the scheduler to switch to another task, potentially giving the >>> vcpu holding the spinlock a chance to run sooner. >>> >> >> Idea looks to be correct from my experiments on x86. It does bring some >> percentage of benefits in overcommitted guests. Infact, >> >> https://lkml.org/lkml/2013/7/22/41 tries to do the same thing for x86. >> (this results in using ple handler heuristics in vcpu_block pach). > > What about the adverse effect in the non-overcommitted case? > Ideally is should fail to schedule any other task and comeback to halt loop. This should not hurt AFAICS. But I agree that, numbers needed to support this argument. For x86, I had seen no side effects with the experiments.