From: Keir Fraser Subject: Re: CPU enumeration in Xen Date: Wed, 22 Aug 2007 14:53:08 +0100 Message-ID: References: <20070822134855.GB18061@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <20070822134855.GB18061@redhat.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: "Daniel P. Berrange" Cc: xen-devel@lists.xensource.com, Dominik Klein List-Id: xen-devel@lists.xenproject.org On 22/8/07 14:48, "Daniel P. Berrange" wrote: >> To my knowledge the enumeration order is determined by the order we find >> CPUs in the BIOS tables, and can hence vary across different systems, and >> even across BIOS upgrades. > > The HV may enumerate CPUs in the same way as Linux baremetal, but Dom0 sees > VCPUs not physical CPUs. So /proc/cpuinfo in Dom0 will bear little resemblance > to the same file on a bare metal machine. You'd need to compare the HV's view > of physical CPUs to the Linux bare metal view, which isn't something you can > do by merely comparing /proc/cpuinfo AFAICT. Oh yes, I missed this stunningly obvious point. :-) If you want to tie dom0 VCPUs 1:1 with physical CPUs then you can put dom0_vcpus_pin on your Xen command line. To see how Xen enumerates the CPUs: look at 'xm dmesg', or look at Xen boot output, to see APIC IDs of processors as they are booted. -- Keir