git-pthread_self
authorGNU Libc Maintainers <debian-glibc@lists.debian.org>
Wed, 16 Dec 2020 21:33:25 +0000 (21:33 +0000)
committerSamuel Thibault <sthibault@debian.org>
Wed, 16 Dec 2020 21:33:25 +0000 (21:33 +0000)
Committed for glibc 2.32

commit ca843defbcbd2dc95b9342189e5dc430e9bcb743
Author: Samuel Thibault <samuel.thibault@ens-lyon.org>
Date:   Sat Feb 15 14:31:50 2020 +0000

    htl: Only check pthread_self coherency when DEBUG is set

    htl has been widely tested for a long time now with this coherency
    checked successfully.

Gbp-Pq: Topic hurd-i386
Gbp-Pq: Name git-pthread_self.diff

sysdeps/mach/hurd/htl/pt-sysdep.h

index c837415a9a16719cc70f50fc6dedb6f1420bd04d..484d024bb059d83d016deedcf7d8934f0f579ec2 100644 (file)
@@ -32,6 +32,7 @@
   mach_msg_header_t wakeupmsg;
 
 extern __thread struct __pthread *___pthread_self;
+#ifdef DEBUG
 #define _pthread_self()                                            \
        ({                                                         \
          struct __pthread *thread;                                \
@@ -46,6 +47,9 @@ extern __thread struct __pthread *___pthread_self;
                      ok; }));                                      \
           thread;                                                  \
          })
+#else
+#define _pthread_self() ___pthread_self
+#endif
 
 extern inline void
 __attribute__ ((__always_inline__))