In article <20120912072608.gr10...@homeworld.netbsd.org>,
Emmanuel Dreyfus  <m...@netbsd.org> wrote:
>On Tue, Sep 11, 2012 at 11:20:47PM -0700, Matt Thomas wrote:
>> _UC_TLSBASE is an MD thing.
>
>iMO it is a MI interface with a MD implementation. It just says whether 
>TLS is part of struct mcontext or not. The MD code can handle that in 
>the kernel or in userland if that is possible.
>
>> Defining it unconditionally bloats things.
>> For instance, if _UC_TLSBASE isn't defined, pthread_setcontext doesn't
>> need to do anything except call setcontext.  That's a win.
>
>But do we have any port that are in this situation? I understand
>they all change the TLS pointer with setcontext.

This is orthogonal. I believe that in the discussion we had in core
we decided to not define _UC_TLSBASE unconditionally, and that ports
should define it as needed. If in the end all ports define _UC_TLSBASE,
then the #ifdef code in libpthread can be removed, but even in that
case I don't see the benefit.

christos

Reply via email to