qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Richard Henderson <rth@twiddle.net>
To: David Munday <cromom@soe.ucsc.edu>
Cc: qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] NPTL user mode fixes
Date: Wed, 28 Apr 2010 11:56:44 -0700	[thread overview]
Message-ID: <4BD884EC.3060403@twiddle.net> (raw)
In-Reply-To: <015e01cae594$3de6d920$b9b48b60$@ucsc.edu>

On 04/26/2010 04:00 PM, David Munday wrote:
> I starting to work with qemu to enable NPTL dependent binaries to run in
> user mode. I see that currently NPTL is not supported for SPARC or x86.
> 
> What is still left to do for NPTL support?

The thing that's missing to enable the compile with NPTL is cpu_set_tls.
For Sparc I believe this is merely an assignment to %g7.  For x86, you
need to arrange for a call to do_set_thread_area, which is currently
private to linux-user/syscall.c.

However, the other thing that will need to be fixed is that neither port
implements its atomic operations atomically -- the implementations merely
assume that only one thread is active.  See do_store_exclusive in
linux-user/main.c for how several ports handle their atomic operations.
It'll be a bit different for Sparc singe it has LDSTUB and SWAP as well
as CAS.  It'll be lots different for x86, since quite a few read-modify-write
operations can be made atomic by use of the LOCK prefix (this could be 
quite an undertaking, actually).


r~

      parent reply	other threads:[~2010-04-28 19:00 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-04-26 23:00 [Qemu-devel] NPTL user mode fixes David Munday
2010-04-27 18:01 ` Blue Swirl
2010-04-28 18:56 ` Richard Henderson [this message]

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=4BD884EC.3060403@twiddle.net \
    --to=rth@twiddle.net \
    --cc=cromom@soe.ucsc.edu \
    --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).