From mboxrd@z Thu Jan 1 00:00:00 1970 From: Konrad Rzeszutek Wilk Subject: Re: PV-vNUMA issue: topology is misinterpreted by the guest Date: Mon, 27 Jul 2015 13:50:58 -0400 Message-ID: <20150727175057.GA13478@konrad-lan.dumpdata.com> References: <1437042762.28251.18.camel@citrix.com> <55B64A8A.7040200@citrix.com> <1438012950.5036.215.camel@citrix.com> <55B65CD6.7000607@citrix.com> <55B65D77.1050202@citrix.com> <1438018925.5036.242.camel@citrix.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mail6.bemta3.messagelabs.com ([195.245.230.39]) by lists.xen.org with esmtp (Exim 4.72) (envelope-from ) id 1ZJmYj-0001Oa-LQ for xen-devel@lists.xenproject.org; Mon, 27 Jul 2015 17:51:29 +0000 Content-Disposition: inline In-Reply-To: <1438018925.5036.242.camel@citrix.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Dario Faggioli Cc: Elena Ufimtseva , Wei Liu , Andrew Cooper , David Vrabel , Jan Beulich , "xen-devel@lists.xenproject.org" , Boris Ostrovsky List-Id: xen-devel@lists.xenproject.org . snip.. > So, it looks to me that: > 1) any application using CPUID for either licensing or > placement/performance optimization will get (potentially) random > results; Right, that is a bug that Andrew outlined in this leveling document I believe. We just pluck the cpuid results on whatever PCPU we were running when the toolstack constructs it. > 2) whatever set of values the kernel used, during guest boot, to build > up its internal scheduling data structures, has no guarantee of > being related to any value returned by CPUID, at a later point. Or after a migration. > > Hence, I think I'm seeing inconsistency between kernel and userspace > (and between userspace and itself, over time) already... Am I > overlooking something? No. I think that is bad. We should be providing the same data - unless pinning is used or any other mechanism is employed to change the cpuid. By default the cpuid ought to be same for a guest throughout its life (lets ignore PV which is 'special'). Also oddly, what is with the SMT threads? On my HVM guests, if I allocate four CPUs (vcpu=4), I get four cores and each core says it has four SMT threads? This is based on /proc/cpuinfo: [konrad@build-external linux]$ cat /proc/cpuinfo |grep "core id" core id : 0 core id : 1 core id : 2 core id : 3 [konrad@build-external linux]$ cat /proc/cpuinfo |grep "siblings" siblings : 4 siblings : 4 siblings : 4 siblings : 4 ? > > (I'll provide the same, for a PV guest, tomorrow.) > > Regards, > Dario > > -- > <> (Raistlin Majere) > ----------------------------------------------------------------- > Dario Faggioli, Ph.D, http://about.me/dario.faggioli > Senior Software Engineer, Citrix Systems R&D Ltd., Cambridge (UK)