Date: Thu, 19 Jun 2003 19:11:46 -0400 (EDT) From: Daniel Eischen <eischen@vigrid.com> To: Marcel Moolenaar <marcel@xcllnt.net> Cc: Julian Elischer <julian@elischer.org> Subject: Re: Implementing TLS: step 1 Message-ID: <Pine.GSO.4.10.10306191904190.8040-100000@pcnet5.pcnet.com> In-Reply-To: <20030619225224.GC1273@dhcp01.pn.xcllnt.net>
next in thread | previous in thread | raw e-mail | index | archive | help
On Thu, 19 Jun 2003, Marcel Moolenaar wrote: > On Thu, Jun 19, 2003 at 03:36:11PM -0700, Julian Elischer wrote: > > Basically in libKSE there is what the kernel calls a thread, which is > > interpretted in userspace as a virtual CPU, and this is used to > > run user level threads. The kernel sets the thread-pointer register > > upcorrectly according to which of these "kernel visible threads" > > is running. This is a legitimate use of the thread pointer register as > > far as I see. In 1:1 (libthr) the two things are the same and it stops > > there. > > It isn't on ia64. The thread pointer register has a predefined > meaning. You cannot point it to anything else than the TLS in > a process that has TLS. (if there's no TLS, the TP register is > unused (=reserved)). > > See also: > http://www.freebsd.org/platforms/ia64/refs.html > > I'm not sure the runtime specification pointed to there has the > TLS info. I'll update the page ASAP if it's missing. Please do. All it says is the TP is the thread pointer and "The usage of this register is ABI specific. Programs conforming to these conventions may not modify this register." I don't see how using it to point to a per-KSE structure abuses its intended use. You must have a different document in mind. The one I looked at was: http://developer.intel.com/design/itanium/downloads/24535803.pdf Titled: "Itanium Software Conventions and Runtime Architecture Guide", May 2001 Or perhaps I just didn't look in the correct section... The above quote was from section 5.2. Thanks, -- Dan Eischen
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.GSO.4.10.10306191904190.8040-100000>
