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

Re: [Xen-devel] How EPT translates an X86_32 guest physical address?

To: Ian Campbell <Ian.Campbell@xxxxxxxxxxxxx>
Subject: Re: [Xen-devel] How EPT translates an X86_32 guest physical address?
From: Chu Rui <ruichu@xxxxxxxxx>
Date: Wed, 17 Nov 2010 19:57:41 +0800
Cc: George Dunlap <George.Dunlap@xxxxxxxxxxxxx>, "Xen-devel@xxxxxxxxxxxxxxxxxxx" <Xen-devel@xxxxxxxxxxxxxxxxxxx>, Superymk <superymkxen@xxxxxxxxxxx>
Delivery-date: Wed, 17 Nov 2010 03:58:59 -0800
Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:received:in-reply-to :references:date:message-id:subject:from:to:cc:content-type; bh=SbTdS/71WPAQBmUKDGvSlGaKXJqYHRuDd+J0/0FtBiY=; b=Dx/VHxSbSYzMgV1iB/Y3/jupLfM3FS5eBbUvUxgbx4Ij346pUG7BE0M9jo3kohToKc Y6wHi69l4otJvWQZ2CkOygJDda7TNNC+duWpWCpmPEDfb3djqYeydDQ8EtDnNOmSxvCU Z1vAiaFMi+u4jvvIkTNT995e7JsV4Trycj+JY=
Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; b=nPx7GKq4SrscTiKRdNB6DnVzTBPPzkl5enEBzVuY8dPq6x46U9R3rFyeMta1Wfv1Na XMuSJXRN8i5AEQkp04agb/HJXLaNrnNRl5ZbgPADBuNqJF8AAizP/evbjZt5lBhql9Yb jLXELYImc/741hKtu67Sds92dcyh8Mgj8gVEo=
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <1289994447.31507.3674.camel@xxxxxxxxxxxxxxxxxxxxxx>
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>
References: <BLU0-SMTP80A291F0F92750E38F3084A2380@xxxxxxx> <AANLkTimG4DCtXSJO0xFoSGgJ_8v46j6W4RU=gUwP+i2L@xxxxxxxxxxxxxx> <BLU0-SMTP170F62EE03BF27EE5AC75FCA2380@xxxxxxx> <AANLkTi=Mu0rom3KCDOQV7tsVnr_sq_npEWEW7FxaFp4T@xxxxxxxxxxxxxx> <BLU0-SMTP204EE298B6F47B9A3CB2B67A2380@xxxxxxx> <4CE3AF56.9030503@xxxxxxxxxxxxx> <1289990998.31507.3506.camel@xxxxxxxxxxxxxxxxxxxxxx> <AANLkTimjjcBS3GujX7XzN1L3bG6YCnxyRt_fn+H0eM2F@xxxxxxxxxxxxxx> <1289994447.31507.3674.camel@xxxxxxxxxxxxxxxxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
Sorry, perhaps I am confused. If the VMM works on the tranditional protect mode with 2-level addressing, what will happen when the guest "thinks" it is working in the x86-64 mode with 4-level addressing?


 
2010/11/17 Ian Campbell <Ian.Campbell@xxxxxxxxxxxxx>
On Wed, 2010-11-17 at 11:26 +0000, Chu Rui wrote:
> Okay, in my mind, the hardware has only one work mode, 32bit or 64bit.
> Thus the 32bit guest address will be extended under the 64bit host.
> But what will happen for a 64bit guest under a 32bit host :-)

You appear to be confusing virtual address size, which is 32 or 64 bit
depending on mode, with phsyical address size, which depends on the
particular CPU model etc and not the mode it is running in.

CPUs these days typically support physical address sizes of something
like 44 or 46 bits, even if they are running in 64 bit mode.

Ian.

>
>
> 2010/11/17 Ian Campbell <Ian.Campbell@xxxxxxxxxx>
>         On Wed, 2010-11-17 at 10:32 +0000, George Dunlap wrote:
>         > The exact implementation of 32-bit mode on a 64-bit capable
>         processor
>         > is something only the engineers at Intel know; but logically
>         yes,
>         > whatever it does is equivalent to first zero-extending the
>         32-bit
>         > value.
>
>
>         Even on x86_32 physical addresses are >32 bit (think PAE). cr3
>         is a
>         physical address, even if the register which exposes it
>         happens to be
>         limited to 32 bits. cr3 has probably already been expanded to
>         a full
>         physical address by the time EPT sees it and I don't think
>         there's any
>         difference between 32 and 64 bit (at least in this aspect) in
>         how EPT
>         handles the translation from physical address to machine
>         address.
>
>         Ian.
>
>



_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
<Prev in Thread] Current Thread [Next in Thread>