All of lore.kernel.org
 help / color / mirror / Atom feed
From: Avi Kivity <avi@redhat.com>
To: Richard Henderson <rth@twiddle.net>
Cc: qemu-devel Developers <qemu-devel@nongnu.org>,
	Aurelien Jarno <aurelien@aurel32.net>
Subject: Re: [Qemu-devel] [RFC] Host vs Guest memory allocation
Date: Mon, 12 Apr 2010 18:09:54 +0300	[thread overview]
Message-ID: <4BC337C2.2090500@redhat.com> (raw)
In-Reply-To: <4BC3345A.6090401@twiddle.net>

On 04/12/2010 05:55 PM, Richard Henderson wrote:
>
>> You could reduce the overhead somewhat by using kvm for memory
>> translation on hosts that support it. Of course tcg translation and
>> syscall costs will grow by the exit overhead.
>
> I've thought about this a bit, and what seemed to be the stickler is
> what is the environment that runs in the guest?  TCG generated code
> is of course fine, but what about the helper functions?  How can we
> tell whether a given helper function can run in the restricted 
> environment of the guest or whether it needs to transition back to the 
> environment of the host to do its work?

I'd guess all helpers can run in guest context except those that cause a 
transition to target kernel mode.

> I suppose the obvious solution is some sort of flag on the function 
> that well-maintained ports will set.  But the whole marshalling thing 
> is still pretty tricky.

Pass everything through memory; will there be many transitions apart 
from trapping instructions and missing translations?

For extra points run the translator in guest context.

-- 
I have a truly marvellous patch that fixes the bug which this
signature is too narrow to contain.

  reply	other threads:[~2010-04-12 15:10 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-04-05 22:45 [Qemu-devel] [RFC] Host vs Guest memory allocation Richard Henderson
2010-04-05 23:18 ` Aurelien Jarno
2010-04-12 11:48   ` Avi Kivity
2010-04-12 14:55     ` Richard Henderson
2010-04-12 15:09       ` Avi Kivity [this message]
2010-04-12 15:39         ` Alexander Graf
2010-04-12 15:49           ` Avi Kivity
2010-04-12 15:56             ` Alexander Graf
2010-04-12 16:08               ` Avi Kivity
2010-04-12 11:25 ` Paul Brook
2010-04-12 14:48   ` Richard Henderson

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=4BC337C2.2090500@redhat.com \
    --to=avi@redhat.com \
    --cc=aurelien@aurel32.net \
    --cc=qemu-devel@nongnu.org \
    --cc=rth@twiddle.net \
    /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.