[[!meta copyright="Copyright © 2011, 2012, 2013 Free Software Foundation, Inc."]] [[!meta license="""[[!toggle id="license" text="GFDL 1.2+"]][[!toggleable id="license" text="Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation; with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts. A copy of the license is included in the section entitled [[GNU Free Documentation License|/fdl]]."]]"""]] [[!tag open_issue_glibc open_issue_libpthread]] This basically means to get rid of `sysdeps/mach/hurd/bits/libc-tsd.h` (and thus the `_HURD_THREADVAR_*`/`_hurd_threadvar_location` interface), and directly use `__thread` instead. [[!toc]] # IRC, freenode, #hurd, 2011-10-23 youpi: If we want to replace threadvars with TLS, there is one problem: the threadvars interface is publically exported: /usr/include/hurd/threadvar.h. youpi: But I am somewhat inclined to say that the only user of this is libthreads/libpthread. Do you think differently? tschwinge: that's very probable so I think we can just drop it (people should use TLS anyway) [[libpthread_set_stack_size]]. After this has been done, probably the whole `__libc_tsd_*` stuff can be dropped altogether, and `__thread` directly be used in glibc. # IRC, freenode, #hurd, 2012-08-07 r5219: Update libpthread patch to replace threadvar with tls for pthread_self r5224: revert r5219 too, it's not ready either as the changelog says, the __thread revertal is because it posed problems and I just didn't have any time to check them while the freeze was so close OK. What kind of problems? Should it be reverted upstream, too? I don't remember exactly it should just be fixed we can revert it upstream, but it'd be good that we manage to progress, at some point... Of course -- however as long as we don't know what kind of problem, it is a bit difficult. ;-) since I didn't left a note, it was most probably a mere glibc run, or boot with the patched libpthread *testsuite run OK. The libpthread testsuite doesn't show any issues with that patch applied, though. But I didn'T test anything else. youpi: Also, you have probably seen my glibc __thread errno email -- rmcgrath wanted to find some time this week to comment/help, and I take it you don't have any immediate comments to that issue? I saw the mails, but didn't investigate at all [[!message-id "878vdyqht3.fsf@kepler.schwinge.homeip.net"]]. # IRC, freenode, #hurd, 2013-07-08 tschwinge: apparently there were a lot of changes missing in the threadvars branch I had commited long time ago I'm gathering things youpi: t/tls-threadvar you mean? yes tschwinge: yes, there were a lot other occurences of threadvars stuff in various places I'm building libc again, and will see what issue would remain ## IRC, freenode, #hurd, 2013-07-12 braunr: about the per-thread ports, there is also the mig reply port (stored in _HURD_THREADVAR_MIG_REPLY) ## IRC, freenode, #hurd, 2013-07-15 and with the branch youpi pushed where he removes threadvars, it shouldn't get "too" hard (save for the tricky bugs you may encounter) well, that branch is not working yet ## IRC, OFTC, #debian-hurd, 2013-09-22 I'm currently tracking bugs with my threadvars changes some of them seem fine, others, not of course the most complex ones are the most probable culprits for the issues I'm getting fortunately they're after the process bootstrap so basically that works just a few dozen tests fail mostly about loading .so or raising signals dlopen("bug-dlsym1-lib1.so"): bug-dlsym1-lib1.so: cannot open shared object file: Function not implemented after having changed errno a bit doesn't that look odd ? :) good, I found an issue with the sigstate now running testsuite again, to see whether there are other issues with it :) s/sigstate/reply_port/ actually ## IRC, OFTC, #debian-hurd, 2013-09-23 yay, errno threadvar conversion success