WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

[Xen-devel] Re: x86 emulator and new isa additions

To: Jan Beulich <JBeulich@xxxxxxxx>
Subject: [Xen-devel] Re: x86 emulator and new isa additions
From: Keir Fraser <keir@xxxxxxx>
Date: Tue, 15 Nov 2011 13:30:53 +0000
Cc: "xen-devel@xxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxx>
Delivery-date: Tue, 15 Nov 2011 05:31:37 -0800
Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=sender:user-agent:date:subject:from:to:cc:message-id:thread-topic :thread-index:in-reply-to:mime-version:content-type :content-transfer-encoding; bh=k1K1imS9AgCVqoulBBpN9o2G7HyTqbmVygHEWHZ+nb4=; b=LEyR7wYtWkehG28NgAyb3DP3uGKIehr5okKV0GHLNhAG1rXN542A7U/d/3loCX8u4P tFiZrcCV8JCs7HcMAZqFq/IsU6XDlr/9nhiD1hNPNet2FrHSq7wyzt68yWlMUcSHLZOD dmSqK2pVZYOHDE7Ah5u3EbMaYv4UkkirytQz4=
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <4EC27134020000780006112C@xxxxxxxxxxxxxxxxxxxx>
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
Thread-index: AcyjmswDdqnGiDtQ8kKGmJ6jaBeHJw==
Thread-topic: x86 emulator and new isa additions
User-agent: Microsoft-Entourage/12.31.0.110725
On 15/11/2011 13:03, "Jan Beulich" <JBeulich@xxxxxxxx> wrote:

> Hi Keir,
> 
> so far the convention seems to be to assume that guest attempts to
> execute instructions not supported by the underlying CPU would never
> make it into the emulator. Is that really correct (in particular in the
> context of real mode emulation, where it's not just single instructions
> that get emulated)?
> 
> From earlier work on the emulation code I seem to recall that it's mainly
> the testing code that didn't like use of cpu_has_xyz in conditionals. I
> would suppose that simply adding respective feature detection (and
> boolean variables) to the testing code should get us around this
> problem. Or would you see any better alternative?

I'm fine to have further feature checks in the emulator, but I would like to
keep the emulator core clean. And indeed the emulator probably ought to act
based on features advertised to the *guest* rather than the *host*?

So, properly, I think the fact we already have a cpuid callback ought to be
sufficient to implement all the cpu_has functionality that the emulator
could want, perhaps hidden behind some helper/abstraction functions/macros.

The question would then be whether that is fast enough. My guess is it would
be, and I'd rather do it that way, or close to that way, in the first
instance at least, and then optimise later if we see the need.

 -- Keir

> Jan
> 



_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel

<Prev in Thread] Current Thread [Next in Thread>