From: Ralf Baechle <ralf@linux-mips.org>
To: Thiemo Seufer <ths@networkno.de>
Cc: Carl van Schaik <carl@ok-labs.com>, linux-mips@linux-mips.org
Subject: Re: TLS register for NPTL
Date: Mon, 20 Aug 2007 15:54:49 +0100 [thread overview]
Message-ID: <20070820145449.GA11766@linux-mips.org> (raw)
In-Reply-To: <20070820080627.GF4479@networkno.de>
On Mon, Aug 20, 2007 at 09:06:27AM +0100, Thiemo Seufer wrote:
> > It seems the rdhwr emulation is used/proposed for accessing the thread
> > word in NPTL.
> > I've been reading some of the posts from 2005 about this choice of this
> > and what I have missed is anyone talking about using the "k0" register
> > for TLS. It seems logical that the kernel could always restore k0 on
> > returning to user-land and having k1 only for the last part of returning
> > to user is sufficient. Any reason why this was not looked at?
>
> The TLB handlers need k0/k1 as well and have no good place to save/restore
> a register.
It can be done but would require several extra instructions in the most
performance sensitive parts of the OS.
Aside, latest MIPS processors support a hardware implementation of rdhwr $29,
so there is no more emulation overhead for this instruction at full binary
compatibility.
Ralf
next prev parent reply other threads:[~2007-08-20 14:56 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-08-20 6:59 TLS register for NPTL Carl van Schaik
2007-08-20 8:06 ` Thiemo Seufer
2007-08-20 14:54 ` Ralf Baechle [this message]
2007-08-21 1:53 ` Carl van Schaik
2007-08-21 12:42 ` Ralf Baechle
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=20070820145449.GA11766@linux-mips.org \
--to=ralf@linux-mips.org \
--cc=carl@ok-labs.com \
--cc=linux-mips@linux-mips.org \
--cc=ths@networkno.de \
/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