about summary refs log tree commit diff
path: root/sysdeps/powerpc/nptl/tcb-offsets.sym
diff options
context:
space:
mode:
authorAdhemerval Zanella <azanella@linux.vnet.ibm.com>2014-06-12 09:32:53 -0500
committerAdhemerval Zanella <azanella@linux.vnet.ibm.com>2014-06-17 07:54:22 -0500
commit556f529dabd3aa57ae1b40a1a5c8d5cc162d4104 (patch)
tree75fb8c4d1956280797a943d1b64fee3227db64db /sysdeps/powerpc/nptl/tcb-offsets.sym
parent4b266200764bc683613090da18af63fa43851051 (diff)
downloadglibc-556f529dabd3aa57ae1b40a1a5c8d5cc162d4104.tar.gz
glibc-556f529dabd3aa57ae1b40a1a5c8d5cc162d4104.tar.xz
glibc-556f529dabd3aa57ae1b40a1a5c8d5cc162d4104.zip
PowerPC: Move powerpc code out of nptl/ subdirectory
Diffstat (limited to 'sysdeps/powerpc/nptl/tcb-offsets.sym')
-rw-r--r--sysdeps/powerpc/nptl/tcb-offsets.sym23
1 files changed, 23 insertions, 0 deletions
diff --git a/sysdeps/powerpc/nptl/tcb-offsets.sym b/sysdeps/powerpc/nptl/tcb-offsets.sym
new file mode 100644
index 0000000000..eac5b5c732
--- /dev/null
+++ b/sysdeps/powerpc/nptl/tcb-offsets.sym
@@ -0,0 +1,23 @@
+#include <sysdep.h>
+#include <tls.h>
+
+--
+
+-- Abuse tls.h macros to derive offsets relative to the thread register.
+# undef __thread_register
+# define __thread_register	((void *) 0)
+# define thread_offsetof(mem)	((ptrdiff_t) THREAD_SELF + offsetof (struct pthread, mem))
+
+
+#if TLS_MULTIPLE_THREADS_IN_TCB
+MULTIPLE_THREADS_OFFSET		thread_offsetof (header.multiple_threads)
+#endif
+PID				thread_offsetof (pid)
+TID				thread_offsetof (tid)
+POINTER_GUARD			(offsetof (tcbhead_t, pointer_guard) - TLS_TCB_OFFSET - sizeof (tcbhead_t))
+TAR_SAVE			(offsetof (tcbhead_t, tar_save) - TLS_TCB_OFFSET - sizeof (tcbhead_t))
+DSO_SLOT1			(offsetof (tcbhead_t, dso_slot1) - TLS_TCB_OFFSET - sizeof (tcbhead_t))
+DSO_SLOT2			(offsetof (tcbhead_t, dso_slot2) - TLS_TCB_OFFSET - sizeof (tcbhead_t))
+#ifndef __ASSUME_PRIVATE_FUTEX
+PRIVATE_FUTEX_OFFSET		thread_offsetof (header.private_futex)
+#endif