Implementing TLS: step 1
Julian Elischer
julian at elischer.org
Fri Jun 20 10:49:32 PDT 2003
On Fri, 20 Jun 2003, Igor Sysoev wrote:
> If we could sacrifice our current thread compatibility in 5.0-5.1
> then we could change kse_mailbox from
>
> struct kse_mailbox {
> int km_version; /* Mailbox version */
> struct kse_thr_mailbox *km_curthread; /* Current thread */
> ...
>
> to
>
> struct kse_mailbox {
> struct kse_thr_mailbox *km_curthread; /* Current thread */
> int km_version; /* Mailbox version */
> ...
>
> then x86's gs would still point to kse_mailbox, and gs:[0] would be
> and TP pointer. Also we need to modify
>
> struct kse_thr_mailbox {
> + void *tls;
> ucontext_t tm_context; /* User thread context */
> ...
>
> And the static TLS must be allocated before kse_thr_mailbox.
Yes.
This is what I was thinking...
>
>
> Igor Sysoev
> http://sysoev.ru/en/
>
> _______________________________________________
> freebsd-threads at freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-threads
> To unsubscribe, send any mail to "freebsd-threads-unsubscribe at freebsd.org"
>
More information about the freebsd-threads
mailing list