All of lore.kernel.org
 help / color / mirror / Atom feed
From: Paul Brook <paul@codesourcery.com>
To: qemu-devel@nongnu.org
Cc: riku.voipio@iki.fi, agraf@suse.de, Aurelien Jarno <aurelien@aurel32.net>
Subject: Re: [Qemu-devel] Re: [PATCH 01/12] TCG "sync" op
Date: Wed, 11 Nov 2009 00:56:47 +0000	[thread overview]
Message-ID: <200911110056.48147.paul@codesourcery.com> (raw)
In-Reply-To: <20091022210317.GO1883@hall.aurel32.net>

On Thursday 22 October 2009, Aurelien Jarno wrote:
> On Wed, Oct 21, 2009 at 03:52:22PM +0200, Ulrich Hecht wrote:
> > sync allows concurrent accesses to locations in memory through different
> > TCG variables. This comes in handy when you are emulating CPU registers
> > that can be used as either 32 or 64 bit, as TCG doesn't know anything
> > about aliases. See the s390x target for an example.
> >
> > Fixed sync_i64 build failure on 32-bit targets.
> 
> Looking more in details to the use case of this patch, I think it can be
> useful in QEMU. However I don't feel very comfortable in merging it
> without having the opinion of more persons. Paul, Malc Blue Swirl or
> others, any opinion?

I don't think this is the right solution.

IIUC the basic problem is that we have a register file where adjacent pairs of 
32-bit registers are also accessed as a 64-bit value.  This is something many 
other targets need to do (at least ARM, PPC, MIPS and SPARC).

While sync appears attractive as a quick hack to achieve this, I think it is 
liable to be abused, and cause us serious pain long-term. If you need an easy 
solution then use ld/st (as with ARM VFP registers). If you want a good 
solution then fix whichever bit of TCG makes accessing a pair of registers 
horribly slow. We already have some support for this (concat_i32_i64).

Paul

  parent reply	other threads:[~2009-11-11  0:56 UTC|newest]

Thread overview: 25+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-10-21 13:52 [Qemu-devel] [PATCH 00/12] S/390 support Ulrich Hecht
2009-10-21 13:52 ` [Qemu-devel] [PATCH 01/12] TCG "sync" op Ulrich Hecht
2009-10-21 13:52   ` [Qemu-devel] [PATCH 02/12] S/390 disassembler fixes Ulrich Hecht
2009-10-21 13:52     ` [Qemu-devel] [PATCH 03/12] S/390 CPU emulation Ulrich Hecht
2009-10-21 13:52       ` [Qemu-devel] [PATCH 04/12] S/390 host build system support Ulrich Hecht
2009-10-21 13:52         ` [Qemu-devel] [PATCH 05/12] S/390 target " Ulrich Hecht
2009-10-21 13:52           ` [Qemu-devel] [PATCH 06/12] S/390 host support for TCG Ulrich Hecht
2009-10-21 13:52             ` [Qemu-devel] [PATCH 07/12] linux-user: S/390 64-bit (s390x) support Ulrich Hecht
2009-10-21 13:52               ` [Qemu-devel] [PATCH 08/12] linux-user: don't do locking in single-threaded processes Ulrich Hecht
2009-10-21 13:52                 ` [Qemu-devel] [PATCH 09/12] linux-user: dup3, fallocate syscalls Ulrich Hecht
2009-10-21 13:52                   ` [Qemu-devel] [PATCH 10/12] linux-user: define a couple of syscalls for non-uid16 targets Ulrich Hecht
2009-10-21 13:52                     ` [Qemu-devel] [PATCH 11/12] linux-user: getpriority errno fix Ulrich Hecht
2009-10-21 13:52                       ` [Qemu-devel] [PATCH 12/12] enable CPU_QuadU for s390x Ulrich Hecht
2009-10-22 21:51     ` [Qemu-devel] [PATCH 02/12] S/390 disassembler fixes Aurelien Jarno
2009-10-22 21:03   ` [Qemu-devel] Re: [PATCH 01/12] TCG "sync" op Aurelien Jarno
2009-10-22 21:27     ` malc
2009-11-11  0:56     ` Paul Brook [this message]
2009-11-16 13:54       ` Alexander Graf
2009-11-16 14:37         ` Paul Brook
2009-11-16 15:14           ` Alexander Graf
2009-11-17 23:40       ` Aurelien Jarno
2009-11-18  0:01         ` Alexander Graf
2009-11-18 15:12           ` Aurelien Jarno
2009-11-18 15:21             ` Alexander Graf
2009-11-18 15:33               ` Paul Brook

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=200911110056.48147.paul@codesourcery.com \
    --to=paul@codesourcery.com \
    --cc=agraf@suse.de \
    --cc=aurelien@aurel32.net \
    --cc=qemu-devel@nongnu.org \
    --cc=riku.voipio@iki.fi \
    /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.