From mboxrd@z Thu Jan 1 00:00:00 1970 From: Avi Kivity Subject: Re: [PATCH 1/3] KVM: MMU: Make pte_list_desc fit cache lines well Date: Thu, 15 Mar 2012 11:22:21 +0200 Message-ID: <4F61B4CD.5020205@redhat.com> References: <20120315181856.2ced0a28.yoshikawa.takuya@oss.ntt.co.jp> <20120315181943.66eb7284.yoshikawa.takuya@oss.ntt.co.jp> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: mtosatti@redhat.com, kvm@vger.kernel.org To: Takuya Yoshikawa Return-path: Received: from mx1.redhat.com ([209.132.183.28]:16714 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756658Ab2COJW0 (ORCPT ); Thu, 15 Mar 2012 05:22:26 -0400 In-Reply-To: <20120315181943.66eb7284.yoshikawa.takuya@oss.ntt.co.jp> Sender: kvm-owner@vger.kernel.org List-ID: On 03/15/2012 11:19 AM, Takuya Yoshikawa wrote: > We have PTE_LIST_EXT + 1 pointers in this structure and these 40/20 > bytes do not fit cache lines well. Furthermore some allocators may > use 64/32-byte objects for the pte_list_desc cache. > > This patch solves this problem by raising PTE_LIST_EXT to 7. > > Note: with EPT/NPT we almost always have a single spte in each reverse > mapping and nothing will be changed by this. It might be better to drop it to 3. Without EPT/NPT, anonymous guest pages will have two mappings (a kernel mapping and a user mapping). Only file pages will have many mappings. -- error compiling committee.c: too many arguments to function