www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 15270] New: use TLS to store Thread.getThis


          Issue ID: 15270
           Summary: use TLS to store Thread.getThis (pthread_getspecific
                    causes heavy lock contention)
           Product: D
           Version: D2
          Hardware: All
                OS: Linux
            Status: NEW
          Severity: normal
          Priority: P1
         Component: druntime
          Assignee: nobody puremagic.com
          Reporter: code dawg.eu

Before 2.066 Thread.getThis() was stored in a plain TLS variable.
In order to fix issue 11981 this was changed to use pthread_getspecific.
Apparently this is a huge performance issue (see

Oct 30 2015