qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: "Andreas Färber" <afaerber@suse.de>
To: Peter Maydell <peter.maydell@linaro.org>
Cc: QEMU Developers <qemu-devel@nongnu.org>, Alexander Graf <agraf@suse.de>
Subject: Re: [Qemu-devel] throwing away translated code on CPU reset
Date: Thu, 12 Jan 2012 15:18:12 +0100	[thread overview]
Message-ID: <4F0EEBA4.1010500@suse.de> (raw)
In-Reply-To: <CAFEAcA9atCC11RiuORHAF7Nf6xnXBCDCM=GM7jDfOW9bsm7KYg@mail.gmail.com>

Am 12.01.2012 15:00, schrieb Peter Maydell:
> When doing TCG code translation, the target-foo translate.c
> code is allowed to bake assumptions into the generated code from
> the current values of various fields in the CPUState. This then
> imposes the requirement that if the field is changed then tb_flush
> must be called to throw away the now-incorrect generated code.
> 
> However, cpu_reset() changes (unsurprisingly) lots of fields in
> the CPUState, but it doesn't call tb_flush()...
> 
> So should cpu_reset() implementations be changed to call tb_flush()
> as well as tlb_flush(), or is this supposed to work in some other
> way?

I would rather suggest to introduce a new cpu_common_reset() that hides
these details - memset() for common parts and whatever necessary here.

Andreas

-- 
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany
GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer; HRB 16746 AG Nürnberg

  reply	other threads:[~2012-01-12 14:20 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-01-12 14:00 [Qemu-devel] throwing away translated code on CPU reset Peter Maydell
2012-01-12 14:18 ` Andreas Färber [this message]
2012-01-13  7:55 ` 陳韋任
2012-01-13  9:08   ` Peter Maydell
2012-01-14 14:48 ` Aurelien Jarno
2012-01-15 16:43   ` Peter Maydell

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=4F0EEBA4.1010500@suse.de \
    --to=afaerber@suse.de \
    --cc=agraf@suse.de \
    --cc=peter.maydell@linaro.org \
    --cc=qemu-devel@nongnu.org \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).