aboutsummaryrefslogtreecommitdiff
path: root/sysdeps/unix
diff options
context:
space:
mode:
authorRichard Henderson <rth@redhat.com>2004-09-06 01:12:02 +0000
committerRichard Henderson <rth@redhat.com>2004-09-06 01:12:02 +0000
commitdf8419fe0a67841bcc7ab47283eaa8cd20bf9043 (patch)
tree3d40acd142f334da4b6c68e66e3e27ff6c219331 /sysdeps/unix
parent99e111a7c22d9da5f7a7b2930e71bbea2fec40b4 (diff)
downloadglibc-df8419fe0a67841bcc7ab47283eaa8cd20bf9043.tar
glibc-df8419fe0a67841bcc7ab47283eaa8cd20bf9043.tar.gz
glibc-df8419fe0a67841bcc7ab47283eaa8cd20bf9043.tar.bz2
glibc-df8419fe0a67841bcc7ab47283eaa8cd20bf9043.zip
* sysdeps/unix/sysv/linux/alpha/sysdep-cancel.h (SINGLE_THREAD_P):
Move definition inside libpthread, libc, librt check. Provide definition for rtld.
Diffstat (limited to 'sysdeps/unix')
-rw-r--r--sysdeps/unix/sysv/linux/alpha/nptl/sysdep-cancel.h35
1 files changed, 20 insertions, 15 deletions
diff --git a/sysdeps/unix/sysv/linux/alpha/nptl/sysdep-cancel.h b/sysdeps/unix/sysv/linux/alpha/nptl/sysdep-cancel.h
index 794d7fc442..f3f7718e3e 100644
--- a/sysdeps/unix/sysv/linux/alpha/nptl/sysdep-cancel.h
+++ b/sysdeps/unix/sysv/linux/alpha/nptl/sysdep-cancel.h
@@ -137,28 +137,33 @@ __LABEL($syscall_error) \
# define CDISABLE jsr ra, __local_disable_asynccancel; ldgp ra, 0(gp)
# endif
-#endif
-
-#if defined IS_IN_libpthread || !defined NOT_IN_libc
-# ifndef __ASSEMBLER__
+# if defined IS_IN_libpthread || !defined NOT_IN_libc
+# ifndef __ASSEMBLER__
extern int __local_multiple_threads attribute_hidden;
-# define SINGLE_THREAD_P \
+# define SINGLE_THREAD_P \
__builtin_expect (__local_multiple_threads == 0, 1)
-# elif defined(PIC)
-# define SINGLE_THREAD_P(reg) ldl reg, __local_multiple_threads(gp) !gprel
-# else
-# define SINGLE_THREAD_P(reg) \
+# elif defined(PIC)
+# define SINGLE_THREAD_P(reg) ldl reg, __local_multiple_threads(gp) !gprel
+# else
+# define SINGLE_THREAD_P(reg) \
ldah reg, __local_multiple_threads(gp) !gprelhigh; \
ldl reg, __local_multiple_threads(reg) !gprellow
-# endif
-#else
-# ifndef __ASSEMBLER__
-# define SINGLE_THREAD_P \
+# endif
+# else
+# ifndef __ASSEMBLER__
+# define SINGLE_THREAD_P \
__builtin_expect (THREAD_GETMEM (THREAD_SELF, \
header.multiple_threads) == 0, 1)
-# else
-# define SINGLE_THREAD_P(reg) \
+# else
+# define SINGLE_THREAD_P(reg) \
call_pal PAL_rduniq; \
ldl reg, MULTIPLE_THREADS_OFFSET($0)
+# endif
# endif
+
+#else
+
+# define SINGLE_THREAD_P (1)
+# define NO_CANCELLATION 1
+
#endif