Re: Accessing pthread_key_create thread-specific data
Florian Weimer via Gdb <[email protected]>
| Newsgroups | gmane.comp.gdb.devel |
|---|---|
| Message-ID | <[email protected]> |
* Tom Tromey: >>>>>> "Florian" == Florian Weimer via Gdb <[email protected]> writes: > > Florian> We have some functionality in libthread_db in glibc that provides access > Florian> to pthread_key_create thread-specific data (aka pthread_setspecific and > Florian> pthread_getspecific). I would like to write a GDB test for this > Florian> functionality, but I can't find how GDB exposes this data in the UI. Is > Florian> this just dead code? > > As far as I know, these aren't used and I think have never been used. Thanks for conforming. > I'm not sure how I would go about exposing this to users. The most > natural way might be to intercept calls to pthread_*specific. Maybe a > couple of new convenience functions would be good though, and less > magical. > > I guess this would primarily be useful for core file debugging? That's a good point. The data structures are not completely trivial to decode even if you have debuginfo symbols. I do not plan to work on that. I just had to make some changes on the glibc side, but I guess I just won't be able to test them. Thanks, Florian