TLS and single/posix thread model in gcc for genode
christian.prochaska at genode-labs.com
Fri Dec 13 16:42:13 CET 2019
On 12.12.19 10:58, Alexander Tormasov via users wrote:
> By default, gcc compiled by toolchain says that thread model is single.
> Is it correct? In particular, what’s with TLS (thread local storage), do we need TLS being enabled via —enable-tls option?
There are different ways of using TLS: one is by declaring variables with the '__thread' or 'thread_local' keywords, another one is
by using functions like 'pthread_setspecific()'. The first way is related to the toolchain, which currently uses the 'emutls'
mechanism to provide the feature . The second way is implemented in . So, in general, TLS should work on Genode. The toolchain
still needs to be rebuilt to get thread-safe exceptions (as stated in issue 3418), but this might be unrelated to your problem with
the golang runtime.
More information about the users