WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

Re: [Xen-devel] Re: NPTL/TLS "emulation" idea (fwd)

To: Rik van Riel <riel@xxxxxxxxxx>
Subject: Re: [Xen-devel] Re: NPTL/TLS "emulation" idea (fwd)
From: Keir Fraser <Keir.Fraser@xxxxxxxxxxxx>
Date: Wed, 20 Oct 2004 15:38:46 +0100
Cc: xen-devel@xxxxxxxxxxxxxxxxxxxxx, jakub@xxxxxxxxxx, roland@xxxxxxxxxx
Delivery-date: Wed, 20 Oct 2004 15:50:38 +0100
Envelope-to: steven.hand@xxxxxxxxxxxx
In-reply-to: Your message of "Wed, 20 Oct 2004 09:27:54 EDT." <Pine.LNX.4.44.0410200927370.3945-100000@xxxxxxxxxxxxxxxxxxxxxxxxxxx>
List-archive: <http://sourceforge.net/mailarchive/forum.php?forum=xen-devel>
List-help: <mailto:xen-devel-request@lists.sourceforge.net?subject=help>
List-id: List for Xen developers <xen-devel.lists.sourceforge.net>
List-post: <mailto:xen-devel@lists.sourceforge.net>
List-subscribe: <https://lists.sourceforge.net/lists/listinfo/xen-devel>, <mailto:xen-devel-request@lists.sourceforge.net?subject=subscribe>
List-unsubscribe: <https://lists.sourceforge.net/lists/listinfo/xen-devel>, <mailto:xen-devel-request@lists.sourceforge.net?subject=unsubscribe>
Sender: xen-devel-admin@xxxxxxxxxxxxxxxxxxxxx
> > A few weeks ago Roland, Jakub and myself brainstormed
> > about this problem.  One of the things that came up is
> > that the positive (glibc private data) and -ve (TLS)
> > data are not generally used at the same time.
> 
> Well, that's not really true.  Small positive offsets are used all the time
> (every syscall, for example, and all of pthreads internals).  Negative
> offsets are used for actual ELF TLS accesses (__thread variables), which
> now include `errno' in the standard glibc build.  So depending on your code
> one or the other might be most common, but you are unlikely ever to have a
> program run that doesn't flip back and forth a fair bit.  I really don't
> have any clue what the fault-segment-flip-resume overhead vs the
> fault-emulate-resume overhead is.  You'd just have to test it out.
> 
> I am still brainstorming about this, but I will need to do some experiments
> to figure out how some other funny ways of using segments actually work.

Yes, so the answer is that we 'flip' about as often as the current
code emulates (e.g., about 2.5 million flips/emulations to boot a Red
Hat system).

The performance is very bad, but the flipping code is both simpler and
more robust than emulation so I will go with the new technique. But I
will still print a warning message from Linux to tell the user to
remove /lib/tls.

 -- Keir


-------------------------------------------------------
This SF.net email is sponsored by: IT Product Guide on ITManagersJournal
Use IT products in your business? Tell us what you think of them. Give us
Your Opinions, Get Free ThinkGeek Gift Certificates! Click to find out more
http://productguide.itmanagersjournal.com/guidepromo.tmpl
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxxxx
https://lists.sourceforge.net/lists/listinfo/xen-devel