Received: from eggs.gnu.org ([2001:4830:134:3::10]:45399) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VE3hP-00087D-4S for qemu-devel@nongnu.org; Mon, 26 Aug 2013 16:47:47 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VE3hK-0001N0-7C for qemu-devel@nongnu.org; Mon, 26 Aug 2013 16:47:43 -0400 Received: from mx1.redhat.com ([209.132.183.28]:59389) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VE3hK-0001Mg-0J for qemu-devel@nongnu.org; Mon, 26 Aug 2013 16:47:38 -0400 Date: Mon, 26 Aug 2013 17:47:29 -0300 From: Eduardo Habkost Message-ID: <20130826204729.GW2631@otherpad.lan.raisama.net> References: <20130813181713.GA5204@irqsave.net> <20130826124031.GB22977@redhat.com> <20130826124941.GA5418@irqsave.net> <20130826143320.GA22899@redhat.com> <20130826164526.GB5418@irqsave.net> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline In-Reply-To: <20130826164526.GB5418@irqsave.net> Content-Transfer-Encoding: quoted-printable Subject: Re: [Qemu-devel] KVM guest cpu L3 cache and cpufreq List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: =?iso-8859-1?Q?Beno=EEt?= Canet Cc: pbonzini@redhat.com, Igor Mammedov , qemu-devel@nongnu.org, Gleb Natapov , Andreas =?iso-8859-1?Q?F=E4rber?= On Mon, Aug 26, 2013 at 06:45:27PM +0200, Beno=EEt Canet wrote: > > Talk to Eduardo since this is related to cpuid configuration and he i= s > > an expert. >=20 > I found the following in target-i386/cpu.c >=20 > case 0x80000006: > /* cache info (L2 cache) */ > *eax =3D 0; > *ebx =3D 0x42004200; > *ecx =3D 0x02008140; > *edx =3D 0; > break; >=20 > From the AMD cpuid book it look like the L3 settings are not defined (e= dx). >=20 > Eduardo: A user I know want to be able to set the size of the guest L3 = cache. > I am ok to write a patch to do so. >=20 > Do you have some recommandations regarding the other fields of the edx = register ? Probably it will be a good idea to let each CPU model have their own defaults for the cache information. > What would be an acceptable user interface to set this ? Things I can remember from the top of my head: * It would be interesting to redo this patch, before doing anything else= : https://github.com/ehabkost/qemu-hacks/commit/10b675fa1269a65a55358654= 5fdbcd95ace79d65 * We need to keep compatibility on existing machine-types (not change the cache size); * If some information is reported on multiple CPUID leaves, we need to keep them consistent with each other (see the FIXME comments on the URL above); * Please use QOM properties to allow the cache sizes/topologies to be se= t. --=20 Eduardo