summaryrefslogtreecommitdiff
path: root/sysdeps
diff options
context:
space:
mode:
Diffstat (limited to 'sysdeps')
-rw-r--r--sysdeps/mach/hurd/bits/libc-tsd.h15
-rw-r--r--sysdeps/mach/hurd/malloc-machine.h8
-rw-r--r--sysdeps/s390/bits/atomic.h4
-rw-r--r--sysdeps/s390/s390-64/dl-trampoline.S2
-rw-r--r--sysdeps/x86_64/configure3
5 files changed, 18 insertions, 14 deletions
diff --git a/sysdeps/mach/hurd/bits/libc-tsd.h b/sysdeps/mach/hurd/bits/libc-tsd.h
index 56393e930d..926dd1fcc1 100644
--- a/sysdeps/mach/hurd/bits/libc-tsd.h
+++ b/sysdeps/mach/hurd/bits/libc-tsd.h
@@ -1,5 +1,5 @@
/* libc-internal interface for thread-specific data. Hurd version.
- Copyright (C) 1998,2002 Free Software Foundation, Inc.
+ Copyright (C) 1998,2002,2008 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
@@ -22,13 +22,14 @@
#include <hurd/threadvar.h>
-#define __libc_tsd_define(CLASS, KEY) /* nothing, always have threadvars */
+#define __libc_tsd_define(CLASS, TYPE, KEY) /* nothing, always have threadvars */
-#define __libc_tsd_address(KEY) \
- ((void **) __hurd_threadvar_location (_HURD_THREADVAR_##KEY))
-
-#define __libc_tsd_get(KEY) (*__libc_tsd_address (KEY))
-#define __libc_tsd_set(KEY, VALUE) (*__libc_tsd_address (KEY) = (VALUE))
+#define __libc_tsd_address(TYPE, KEY) \
+ ((TYPE *) __hurd_threadvar_location (_HURD_THREADVAR_##KEY))
+#define __libc_tsd_get(TYPE, KEY) \
+ (*__libc_tsd_address (TYPE, KEY))
+#define __libc_tsd_set(TYPE, KEY, VALUE) \
+ (*__libc_tsd_address (TYPE, KEY) = (VALUE))
#endif /* bits/libc-tsd.h */
diff --git a/sysdeps/mach/hurd/malloc-machine.h b/sysdeps/mach/hurd/malloc-machine.h
index 70aaf11b87..e6078f60dc 100644
--- a/sysdeps/mach/hurd/malloc-machine.h
+++ b/sysdeps/mach/hurd/malloc-machine.h
@@ -1,6 +1,6 @@
/* Basic platform-independent macro definitions for mutexes,
thread-specific data and parameters for malloc.
- Copyright (C) 2003 Free Software Foundation, Inc.
+ Copyright (C) 2003, 2008 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
@@ -58,10 +58,10 @@
#include <bits/libc-tsd.h>
typedef int tsd_key_t[1]; /* no key data structure, libc magic does it */
-__libc_tsd_define (static, MALLOC) /* declaration/common definition */
+__libc_tsd_define (static, void *, MALLOC) /* declaration/common definition */
#define tsd_key_create(key, destr) ((void) (key))
-#define tsd_setspecific(key, data) __libc_tsd_set (MALLOC, (data))
-#define tsd_getspecific(key, vptr) ((vptr) = __libc_tsd_get (MALLOC))
+#define tsd_setspecific(key, data) __libc_tsd_set (void *, MALLOC, (data))
+#define tsd_getspecific(key, vptr) ((vptr) = __libc_tsd_get (void *, MALLOC))
#include <sysdeps/generic/malloc-machine.h>
diff --git a/sysdeps/s390/bits/atomic.h b/sysdeps/s390/bits/atomic.h
index aa00473413..95d0390d09 100644
--- a/sysdeps/s390/bits/atomic.h
+++ b/sysdeps/s390/bits/atomic.h
@@ -56,7 +56,7 @@ typedef uintmax_t uatomic_max_t;
__typeof (*mem) __archold = (oldval); \
__asm __volatile ("cs %0,%2,%1" \
: "+d" (__archold), "=Q" (*__archmem) \
- : "d" (newval), "m" (*__archmem) : "cc" ); \
+ : "d" (newval), "m" (*__archmem) : "cc", "memory" ); \
__archold; })
#ifdef __s390x__
@@ -65,7 +65,7 @@ typedef uintmax_t uatomic_max_t;
__typeof (*mem) __archold = (oldval); \
__asm __volatile ("csg %0,%2,%1" \
: "+d" (__archold), "=Q" (*__archmem) \
- : "d" ((long) (newval)), "m" (*__archmem) : "cc" ); \
+ : "d" ((long) (newval)), "m" (*__archmem) : "cc", "memory" ); \
__archold; })
#else
/* For 31 bit we do not really need 64-bit compare-and-exchange. We can
diff --git a/sysdeps/s390/s390-64/dl-trampoline.S b/sysdeps/s390/s390-64/dl-trampoline.S
index 8093582163..72043c9779 100644
--- a/sysdeps/s390/s390-64/dl-trampoline.S
+++ b/sysdeps/s390/s390-64/dl-trampoline.S
@@ -91,7 +91,7 @@ _dl_runtime_profile:
ld %f4,120(%r12)
ld %f6,128(%r12)
basr %r14,%r1 # call resolved function
-0: lr %r15,%r12 # remove stack frame
+0: lgr %r15,%r12 # remove stack frame
cfi_def_cfa_register (15)
lg %r14,32(%r15) # restore registers
lg %r12,24(%r15)
diff --git a/sysdeps/x86_64/configure b/sysdeps/x86_64/configure
new file mode 100644
index 0000000000..bd699bbccb
--- /dev/null
+++ b/sysdeps/x86_64/configure
@@ -0,0 +1,3 @@
+# The i386 fragment also works for x86_64.
+
+. $srcdir/sysdeps/i386/configure