aboutsummaryrefslogtreecommitdiff
path: root/nptl/sysdeps/sparc
diff options
context:
space:
mode:
authorDavid S. Miller <davem@davemloft.net>2012-10-05 21:22:41 -0700
committerDavid S. Miller <davem@davemloft.net>2012-10-05 21:22:41 -0700
commitf07621646892e079b4d1eec1b02e5ab03b578a5e (patch)
treef07d3d9497e288fc7913fdee732598ccff638728 /nptl/sysdeps/sparc
parent3baddb72a4181e05d0d279a6b345635641e13a18 (diff)
downloadglibc-f07621646892e079b4d1eec1b02e5ab03b578a5e.zip
glibc-f07621646892e079b4d1eec1b02e5ab03b578a5e.tar.gz
glibc-f07621646892e079b4d1eec1b02e5ab03b578a5e.tar.bz2
Correct libthreadb register access for 64-bit sparc.
[BZ #14568] * sysdeps/sparc/tls.h (DB_THREAD_SELF_INCLUDE): Delete. (DB_THREAD_SELF): Use constants for the register offsets. Correct the case of a 64-bit debugger with a 32-bit inferior.
Diffstat (limited to 'nptl/sysdeps/sparc')
-rw-r--r--nptl/sysdeps/sparc/tls.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/nptl/sysdeps/sparc/tls.h b/nptl/sysdeps/sparc/tls.h
index 61cb09f..cfc9d96 100644
--- a/nptl/sysdeps/sparc/tls.h
+++ b/nptl/sysdeps/sparc/tls.h
@@ -117,9 +117,9 @@ register struct pthread *__thread_self __asm__("%g7");
#define THREAD_SELF __thread_self
/* Magic for libthread_db to know how to do THREAD_SELF. */
-# define DB_THREAD_SELF_INCLUDE <sys/ucontext.h>
# define DB_THREAD_SELF \
- REGISTER (32, 32, REG_G7 * 4, 0) REGISTER (64, 64, REG_G7 * 8, 0)
+ REGISTER (32, 32, 10 * 4, 0) \
+ REGISTER (64, __WORDSIZE, (6 * 8) + (__WORDSIZE==64?0:4), 0)
/* Access to data in the thread descriptor is easy. */
#define THREAD_GETMEM(descr, member) \