From 5fcebcde6aeba6ae4a339790beba5331fbcd3b6e Mon Sep 17 00:00:00 2001 From: Rich Felker Date: Thu, 10 Mar 2011 18:31:37 -0500 Subject: optimize pthread termination in the non-detached case we can avoid blocking signals by simply using a flag to mark that the thread has exited and prevent it from getting counted in the rsyscall signal-pingpong. this restores the original pthread create/join throughput from before the sigprocmask call was added. --- src/internal/pthread_impl.h | 1 + 1 file changed, 1 insertion(+) (limited to 'src/internal') diff --git a/src/internal/pthread_impl.h b/src/internal/pthread_impl.h index adb80f2f..c1740111 100644 --- a/src/internal/pthread_impl.h +++ b/src/internal/pthread_impl.h @@ -36,6 +36,7 @@ struct pthread { struct __ptcb *cancelbuf; void **tsd; pthread_attr_t attr; + volatile int dead; }; #define __SU (sizeof(size_t)/sizeof(int)) -- cgit v1.2.1