This is the mail archive of the gdb-prs@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug threads/11795] New: Support __thread variables without libpthread


echo 'main(){}'|gcc -g -x c -;./gdb -nx -ex start -ex 'p errno' ./a.out 
Cannot find thread-local variables on this target

It happens for any variable marked by __thread when -lpthread is not used.
Fedora GDB has some hacks such as using `*__errno_location()' instead of `errno'.

The proper way would be glibc extension to support __thread variables even
without -lpthread mode as they are used not just for `errno'.
Draft patches included.

-- 
           Summary: Support __thread variables without libpthread
           Product: gdb
           Version: unknown
            Status: UNCONFIRMED
          Severity: enhancement
          Priority: P2
         Component: threads
        AssignedTo: unassigned at sourceware dot org
        ReportedBy: jan dot kratochvil at redhat dot com
                CC: gdb-prs at sourceware dot org


http://sourceware.org/bugzilla/show_bug.cgi?id=11795

------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]