From mboxrd@z Thu Jan 1 00:00:00 1970 From: Dave Jones Subject: Re: para virt cpuid? Date: Tue, 7 Jun 2005 13:06:36 -0400 Message-ID: <20050607170636.GD16344@redhat.com> References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Content-Disposition: inline In-Reply-To: List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: Ian Pratt Cc: Xen Dev List-Id: xen-devel@lists.xenproject.org On Tue, Jun 07, 2005 at 12:15:17PM +0100, Ian Pratt wrote: > > looking at TODO list, i see this stuff: "para virt cpuid > > (/proc/cpuinfo) allow hiding from domains via domain config" > > > > I dont understand what it is. Anybody here could explain this to me? > > Unfortunately, its not possible to trap the cpuid instruction on > standard x86. Which makes it hard to 'hide' certain processor features > from applications and libraries (since we're hacking the kernel we can > get around this inside the kernel). > > You may wish to hide certain features from user applications such that > you can migrate the VM to a different host without worrying whether it > has that feature or not (e.g. migrating from an SSE2 host to one that > doesn't have it). > > Some applications decide whether they can use a CPU feature by reading > from /proc/cpuinfo, in which case we could hide features under the > control of the domain's config. Unfortunately, I fear many (most?) > application libraries probably just go at the cpuid instruction > directly. Either that, or they parse /dev/cpu/N/cpuid, which is again, trappable by the kernel if we so desired. Any apps that do cpuid instruction calls itself is likely broken anyway on SMP machines, unless it also plays games with the scheduler affinity calls. Dave