All of lore.kernel.org
 help / color / mirror / Atom feed
From: Keir Fraser <keir.fraser@eu.citrix.com>
To: James Harper <james.harper@bendigoit.com.au>,
	xen-devel@lists.xensource.com
Subject: Re: TPR write optimization (even improves 2003 sp2)
Date: Thu, 08 Jan 2009 09:07:34 +0000	[thread overview]
Message-ID: <C58B72D6.20DBE%keir.fraser@eu.citrix.com> (raw)
In-Reply-To: <AEC6C66638C05B468B556EA548C1A77D01550264@trantor>

On 08/01/2009 00:40, "James Harper" <james.harper@bendigoit.com.au> wrote:

> I just quickly implemented this as a 'proof of concept' by adding a
> XENMAPSPACE_vlapic_regs function to XENMEM_add_to_physmap, and it works,
> but only after I removed regs_page from the vlapic struct and used
> alloc_xenheap_page instead of alloc_domheap_page and then
> share_xen_page_with_guest. Can I do it with alloc_domheap_page? It
> didn't 'just work' when I did it that way... (and I had to comment out
> the use of regs_page in the vmx code to get it to compile, so as it
> stands it probably wouldn't work on Intel).

Using alloc_xenheap_page would be okay.

> Anyway, in my xp guest when I KeRaiseIrql and then read the mapped
> vlapic->regs from xp I see that the TPR register is changing, so things
> are looking good.
> 
> Next will be to patch windows to:
> . On read, just read from the mapped space instead of the mmio space for
> at least the TPR register, and maybe others if there are potential
> performance gains
> . On write, write the value to the mapped space, then check if an
> interrupt could be pending (as per Keirs algorithm in a previous email),
> and if so, write to the mmio space to force a VMEXIT (or use some other
> way of invoking a VMEXIT if it's faster...). By doing the mapped write
> first before checking for pending interrupts I should avoid any races...

Yes, sounds okay.

 K.

  parent reply	other threads:[~2009-01-08  9:07 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-01-07  2:09 TPR write optimization James Harper
2009-01-07  2:59 ` TPR write optimization (even improves 2003 sp2) James Harper
2009-01-07  8:57   ` Keir Fraser
2009-01-07  9:14     ` James Harper
2009-01-07  9:20       ` Keir Fraser
2009-01-07  9:33         ` James Harper
2009-01-07  9:53           ` Keir Fraser
2009-01-07 10:05             ` James Harper
2009-01-07 10:26               ` Keir Fraser
2009-01-07 12:12                 ` James Harper
2009-01-07 12:15                   ` James Harper
2009-01-07 12:24                   ` Keir Fraser
2009-01-07 22:51                     ` James Harper
2009-01-08  0:40                       ` James Harper
2009-01-08  3:53                         ` James Harper
2009-01-08  9:08                           ` Keir Fraser
2009-01-08  9:10                             ` James Harper
2009-01-08  9:07                         ` Keir Fraser [this message]
2009-01-08  9:09                           ` James Harper
2009-01-08  9:12                             ` Keir Fraser
2009-01-08  9:14                               ` James Harper
2009-01-08  9:14                             ` Keir Fraser
2009-01-08  9:17                               ` James Harper
2009-01-07 12:35                 ` James Harper

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=C58B72D6.20DBE%keir.fraser@eu.citrix.com \
    --to=keir.fraser@eu.citrix.com \
    --cc=james.harper@bendigoit.com.au \
    --cc=xen-devel@lists.xensource.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.