about summary refs log tree commit diff
path: root/nptl_db/db_info.c
diff options
context:
space:
mode:
authorRoland McGrath <roland@gnu.org>2004-03-13 07:59:04 +0000
committerRoland McGrath <roland@gnu.org>2004-03-13 07:59:04 +0000
commitd6f53c6f3e7741a4f8d63431b716740d15ebe431 (patch)
tree6eeda3bd6df593ef9d8387ef26f3be6fb26d963a /nptl_db/db_info.c
parentde079fee8c0f12609c38245432abfbe19c261e86 (diff)
downloadglibc-d6f53c6f3e7741a4f8d63431b716740d15ebe431.tar.gz
glibc-d6f53c6f3e7741a4f8d63431b716740d15ebe431.tar.xz
glibc-d6f53c6f3e7741a4f8d63431b716740d15ebe431.zip
2004-03-12 Roland McGrath <roland@redhat.com>
	* db_info.c [TLS_DTV_AT_TP && TLS_TP_OFFSET > 0]
	(_thread_db_pthread_dtvp): Define differently for this case (PowerPC).
Diffstat (limited to 'nptl_db/db_info.c')
-rw-r--r--nptl_db/db_info.c11
1 files changed, 10 insertions, 1 deletions
diff --git a/nptl_db/db_info.c b/nptl_db/db_info.c
index 4d47b6609d..6ffe8bb058 100644
--- a/nptl_db/db_info.c
+++ b/nptl_db/db_info.c
@@ -1,7 +1,7 @@
 /* This file is included by pthread_create.c to define in libpthread
    all the magic symbols required by libthread_db.
 
-   Copyright (C) 2003 Free Software Foundation, Inc.
+   Copyright (C) 2003, 2004 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
    The GNU C Library is free software; you can redistribute it and/or
@@ -53,6 +53,15 @@ typedef struct link_map link_map;
 
 #if TLS_TCB_AT_TP
 # define dtvp header.dtv
+#elif TLS_DTV_AT_TP && TLS_TP_OFFSET > 0
+/* Special case hack.  Really this #if should be TLS_TCB_SIZE == 0, but
+   when untrue it's a sizeof expression, and that wouldn't fly.  In this
+   flavor (PowerPC), there is no TCB containing the DTV at the TP, but
+   actually the TCB lies behind the TP, i.e. at the very end of the area
+   covered by TLS_PRE_TCB_SIZE.  */
+DESC (_thread_db_pthread_dtvp,
+      TLS_PRE_TCB_SIZE - sizeof (tcbhead_t) + offsetof (tcbhead_t, dtv),
+      union dtv)
 #elif TLS_DTV_AT_TP
 /* Special case hack.  */
 DESC (_thread_db_pthread_dtvp,