Received: by 10.223.176.5 with SMTP id f5csp404363wra; Thu, 1 Feb 2018 23:12:57 -0800 (PST) X-Google-Smtp-Source: AH8x225U/2NpTttKdcb2dKV+5dMExxWvl0XOG6JXg1uI/9jg6avaEoILmC4j/unraRxPfYvewNAl X-Received: by 2002:a17:902:6a81:: with SMTP id n1-v6mr11471734plk.11.1517555577038; Thu, 01 Feb 2018 23:12:57 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1517555577; cv=none; d=google.com; s=arc-20160816; b=iSUVKufSGl5wdn7RXpQyhTum4KMdFoYWzAYUn3bhkDczr0G4WiS+YMU9IjqGzCaDqi FiuxVyscReZvZPQZXP+e6KNuU/vIq+xW4TEHP7+P7EjB+ac7TlME8ybFEcvcGK3+6JyX ryyQw20MEp8MR1OTYE/NHM1DoRWyfX5scxQe11ynsqQCaCzHnoTSlZYbONLaUVrJnRbG zRt9Pdm5e5KcXs4Miz8CUxlbOlO1zIO3NaaROBa68npI5qZRKOuNoWV+sMKTOAGW4oLC qBFwAboXQSnRYcoPgsVTDeuPjsEMfTNMTJhjd3D1ctvqm26Rp4k1kLjjygQhjkm2f/XY h5NA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :dkim-signature:arc-authentication-results; bh=ThTUtAq1UpJKIBViJpHQ6ZyF3+Q0sip141qhGK7JLcU=; b=g2VLLKwsIAFjhST5VZznwAdfOpXScYeb6dvFB2bB1AgwXneNJPawqPFQKhrkci0Waq eD7/RnfV9xxqc7D3DRkgh0XoPjczZVlXlf6oF5+HebYqTaNVS5B1b65jYYVP5kPnD8Xz 6OGxNHkPVdz2EfvVYWImSpY7qSiW9SUdfQCsOwXp5fWDjdALUN3FJtXKbUh6m9PopIfQ jkvSSOddkB8D69G1QRGTxOyRdpFgWjwWMgmRBJDEzAF0bXbtFz56XB/crLBfsMNhPRDS YwEsu/mGLuaF8QutVLFwfZePCuHF+L3Hej735TzTiwfvROiVmuUB78kL1XtoqrNYx08H +Cug== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=BbgIcAnH; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id c5si991249pgq.719.2018.02.01.23.12.41; Thu, 01 Feb 2018 23:12:56 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=BbgIcAnH; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751649AbeBBHMJ (ORCPT + 99 others); Fri, 2 Feb 2018 02:12:09 -0500 Received: from mail-pl0-f68.google.com ([209.85.160.68]:39894 "EHLO mail-pl0-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750781AbeBBHMD (ORCPT ); Fri, 2 Feb 2018 02:12:03 -0500 Received: by mail-pl0-f68.google.com with SMTP id o13so5508783pli.6; Thu, 01 Feb 2018 23:12:03 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id; bh=ThTUtAq1UpJKIBViJpHQ6ZyF3+Q0sip141qhGK7JLcU=; b=BbgIcAnHP0migPvNUECvOp/TPBi8dGgJqlZlPatp53cjMjHs1T83C0ifZ7nCTdK2mC lIATS4aaz6O2vvWn15WN6/dcltaoMAEOlA4Lg+TSqhK+nbrCDBBg+7dMdNOYsm0n2lYe buFiV9R6RROdg6Laesgnoaw1lKeWnE47cz/7VjHyf+t/s7zxTrMXNIMYTizfIW10OYAV q2daIVwc8l+Hkfc7yAPIWgN88oUtB3xbFH+Tsj5MAjsRer4GxrXMv1J1FLJDJhibcJ0Q eupXH41j3dvaunx80aQDxrAJ/92QQllevFtUrx42E1Qq92lIPUALo1pV9noRt0OHvt/w /42g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=ThTUtAq1UpJKIBViJpHQ6ZyF3+Q0sip141qhGK7JLcU=; b=Ay0evyNBkt+ZlgiCotmBmQFpgb03rMfzvj90BTKfgHxh4/95/+PT5H7YasWKH/YCpK 6jlQeShNkiTMSumcEZzuVuqLowGQx6rFebONOJ57sz+mRb0tKy4jUXhzOQqqIJzA2C5F c9WHHK22JKmp2Q0VWmstAplc2pslgg7ULeZMk78zi3Far52cP2/DkCnkIv/swpCJ2Eqi ZluqyNZmcoO9nboyjFiVIA8vb5xl5UJ4vbZv+KaYS9HWwPmRKYX5CdGOXUyM3NvLXVeH gig3TfuzZ3ZjJgFtMwrFJiLRz1QWX5/bxaH6Gmy3xaUQns9aoO6t9C3wBabgoixi+3Rx LeiQ== X-Gm-Message-State: AKwxytcZB2Ua7Fq/vCnCjKWT+lODmA43Wq6XkF0w+CYXJo+KngxoXEpG 3yzF/0W5QgN7CcEv6Ueve6otVg== X-Received: by 2002:a17:902:c81:: with SMTP id 1-v6mr34406770plt.281.1517555522930; Thu, 01 Feb 2018 23:12:02 -0800 (PST) Received: from localhost.localdomain ([203.205.141.123]) by smtp.googlemail.com with ESMTPSA id z5sm2297389pfi.81.2018.02.01.23.12.01 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 01 Feb 2018 23:12:02 -0800 (PST) From: Wanpeng Li X-Google-Original-From: Wanpeng Li To: linux-kernel@vger.kernel.org, kvm@vger.kernel.org Cc: Paolo Bonzini , =?UTF-8?q?Radim=20Kr=C4=8Dm=C3=A1=C5=99?= Subject: [PATCH 0/2] KVM: X86: Add dedicated pCPU hint and per-VM non-HLT-exiting capability Date: Thu, 1 Feb 2018 23:11:11 -0800 Message-Id: <1517555473-8313-1-git-send-email-wanpengli@tencent.com> X-Mailer: git-send-email 2.7.4 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Waiman Long mentioned that: Generally speaking, unfair lock performs well for VMs with a small number of vCPUs. Native qspinlock may perform better than pvqspinlock if there is vCPU pinning and there is no vCPU over-commitment. This patchset adds a PV_DEDICATED performance hint to allow hypervisor admin to choose the qspinlock to be used when a dedicated pCPU is available. In addition, according to the original hlt in VMX non-root mode discussion, https://www.spinics.net/lists/kvm/msg152397.html This patchset also adds the per-VM non-HLT-exiting capability to further improve performance under the dedicated pCPU scenarios. Wanpeng Li (2): KVM: X86: Add dedicated pCPU hint PV_DEDICATED KVM: X86: Add per-VM no-HLT-exiting capability Documentation/virtual/kvm/api.txt | 11 +++++++++++ Documentation/virtual/kvm/cpuid.txt | 6 ++++++ arch/x86/include/asm/kvm_host.h | 2 ++ arch/x86/include/uapi/asm/kvm_para.h | 1 + arch/x86/kernel/kvm.c | 6 ++++++ arch/x86/kvm/vmx.c | 21 +++++++++++++++++++++ arch/x86/kvm/x86.c | 5 +++++ arch/x86/kvm/x86.h | 5 +++++ include/uapi/linux/kvm.h | 1 + 9 files changed, 58 insertions(+) -- 2.7.4