(unwind_backtrace, unwind_getip): Define #ifndef SHARED.
(__backtrace): Don't call init #ifndef SHARED.
* sysdeps/s390/s390-64/backtrace.c (init): Guard with #ifdef SHARED.
(unwind_backtrace, unwind_getip): Define #ifndef SHARED.
(__backtrace): Don't call init #ifndef SHARED.
* sysdeps/ia64/backtrace.c (init): Guard with #ifdef SHARED.
(unwind_backtrace, unwind_getip): Define #ifndef SHARED.
(__backtrace): Don't call init #ifndef SHARED.
+2004-06-08 Jakub Jelinek <jakub@redhat.com>
+
+ * sysdeps/s390/s390-32/backtrace.c (init): Guard with #ifdef SHARED.
+ (unwind_backtrace, unwind_getip): Define #ifndef SHARED.
+ (__backtrace): Don't call init #ifndef SHARED.
+ * sysdeps/s390/s390-64/backtrace.c (init): Guard with #ifdef SHARED.
+ (unwind_backtrace, unwind_getip): Define #ifndef SHARED.
+ (__backtrace): Don't call init #ifndef SHARED.
+ * sysdeps/ia64/backtrace.c (init): Guard with #ifdef SHARED.
+ (unwind_backtrace, unwind_getip): Define #ifndef SHARED.
+ (__backtrace): Don't call init #ifndef SHARED.
+
2004-06-11 Roland McGrath <roland@redhat.com>
* sysdeps/arm/strlen.S [__ARMEB__]: Compute correctly for big-endian.
+2004-06-08 Jakub Jelinek <jakub@redhat.com>
+
+ * pthread_mutexattr_getpshared.c (pthread_mutex_getpshared): Fix
+ comment typo.
+ * pthread_mutexattr_gettype.c (pthread_mutexattr_gettype): Likewise.
+ * pthread_mutexattr_init.c (__pthread_mutexattr_init): Likewise.
+ * pthread_mutexattr_settype.c (__pthread_mutexattr_settype): Likewise.
+ * pthread_mutexattr_setpshared.c (pthread_mutexattr_setpshared):
+ Likewise. Reported by Bob Cook <bobcook47@hotmail.com>.
+
2004-06-11 Martin Schwidefsky <schwidefsky@de.ibm.com>
* sysdeps/unix/sysv/linux/s390/lowlevellock.h (lll_compare_and_swap):
iattr = (const struct pthread_mutexattr *) attr;
- /* We use bit 31 to single whether the mutex is going to be
+ /* We use bit 31 to signal whether the mutex is going to be
process-shared or not. */
*pshared = ((iattr->mutexkind & 0x80000000) != 0
? PTHREAD_PROCESS_SHARED : PTHREAD_PROCESS_PRIVATE);
iattr = (const struct pthread_mutexattr *) attr;
- /* We use bit 31 to single whether the mutex is going to be
+ /* We use bit 31 to signal whether the mutex is going to be
process-shared or not. */
*kind = iattr->mutexkind & ~0x80000000;
if (sizeof (struct pthread_mutexattr) != sizeof (pthread_mutexattr_t))
memset (attr, '\0', sizeof (*attr));
- /* We use bit 31 to single whether the mutex is going to be
+ /* We use bit 31 to signal whether the mutex is going to be
process-shared or not. By default it is zero, i.e., the mutex is
not process-shared. */
((struct pthread_mutexattr *) attr)->mutexkind = PTHREAD_MUTEX_NORMAL;
iattr = (struct pthread_mutexattr *) attr;
- /* We use bit 31 to single whether the mutex is going to be
+ /* We use bit 31 to signal whether the mutex is going to be
process-shared or not. */
if (pshared == PTHREAD_PROCESS_PRIVATE)
iattr->mutexkind &= ~0x80000000;
iattr = (struct pthread_mutexattr *) attr;
- /* We use bit 31 to single whether the mutex is going to be
+ /* We use bit 31 to signal whether the mutex is going to be
process-shared or not. */
iattr->mutexkind = (iattr->mutexkind & 0x80000000) | kind;
/* Return backtrace of current program state.
- Copyright (C) 2003 Free Software Foundation, Inc.
+ Copyright (C) 2003, 2004 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Jakub Jelinek <jakub@redhat.com>, 2003.
int cnt, size;
};
+#ifdef SHARED
static _Unwind_Reason_Code (*unwind_backtrace) (_Unwind_Trace_Fn, void *);
static _Unwind_Ptr (*unwind_getip) (struct _Unwind_Context *);
if (unwind_getip == NULL)
unwind_backtrace = NULL;
}
+#else
+# define unwind_backtrace _Unwind_Backtrace
+# define unwind_getip _Unwind_GetIP
+#endif
static _Unwind_Reason_Code
backtrace_helper (struct _Unwind_Context *ctx, void *a)
int size;
{
struct trace_arg arg = { .array = array, .size = size, .cnt = -1 };
+#ifdef SHARED
__libc_once_define (static, once);
__libc_once (once, init);
if (unwind_backtrace == NULL)
return 0;
+#endif
if (size >= 1)
unwind_backtrace (backtrace_helper, &arg);
/* Return backtrace of current program state.
- Copyright (C) 2000, 2001, 2003 Free Software Foundation, Inc.
+ Copyright (C) 2000, 2001, 2003, 2004 Free Software Foundation, Inc.
Contributed by Martin Schwidefsky (schwidefsky@de.ibm.com).
This file is part of the GNU C Library.
int cnt, size;
};
+#ifdef SHARED
static _Unwind_Reason_Code (*unwind_backtrace) (_Unwind_Trace_Fn, void *);
static _Unwind_Ptr (*unwind_getip) (struct _Unwind_Context *);
if (unwind_getip == NULL)
unwind_backtrace = NULL;
}
+#else
+# define unwind_backtrace _Unwind_Backtrace
+# define unwind_getip _Unwind_GetIP
+#endif
static int
__backchain_backtrace (void **array, int size)
__backtrace (void **array, int size)
{
struct trace_arg arg = { .array = array, .size = size, .cnt = -1 };
+#ifdef SHARED
__libc_once_define (static, once);
__libc_once (once, init);
+#endif
if (unwind_backtrace == NULL)
return __backchain_backtrace (array, size);
/* Return backtrace of current program state. 64 bit S/390 version.
- Copyright (C) 2001, 2003 Free Software Foundation, Inc.
+ Copyright (C) 2001, 2003, 2004 Free Software Foundation, Inc.
Contributed by Martin Schwidefsky (schwidefsky@de.ibm.com).
This file is part of the GNU C Library.
int cnt, size;
};
+#ifdef SHARED
static _Unwind_Reason_Code (*unwind_backtrace) (_Unwind_Trace_Fn, void *);
static _Unwind_Ptr (*unwind_getip) (struct _Unwind_Context *);
if (unwind_getip == NULL)
unwind_backtrace = NULL;
}
+#else
+# define unwind_backtrace _Unwind_Backtrace
+# define unwind_getip _Unwind_GetIP
+#endif
int
__backchain_backtrace (void **array, int size)
__backtrace (void **array, int size)
{
struct trace_arg arg = { .array = array, .size = size, .cnt = -1 };
+#ifdef SHARED
__libc_once_define (static, once);
__libc_once (once, init);
+#endif
if (unwind_backtrace == NULL)
return __backchain_backtrace (array, size);