From 1c4f98663635995919a2fe7f9c4cbf630ae238d2 Mon Sep 17 00:00:00 2001 From: Austin Foxley Date: Fri, 11 Dec 2009 03:46:37 -0800 Subject: get x86_64 nptl building Signed-off-by: Austin Foxley --- .../unix/sysv/linux/x86_64/bits/pthreadtypes.h | 30 +++++++++++++++++----- 1 file changed, 23 insertions(+), 7 deletions(-) (limited to 'libpthread/nptl/sysdeps/unix/sysv/linux/x86_64/bits') diff --git a/libpthread/nptl/sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h b/libpthread/nptl/sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h index 51fdab0fb..7a09c8119 100644 --- a/libpthread/nptl/sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h +++ b/libpthread/nptl/sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h @@ -1,4 +1,4 @@ -/* Copyright (C) 2002, 2003, 2004 Free Software Foundation, Inc. +/* Copyright (C) 2002,2003,2004,2005,2006,2007 Free Software Foundation, Inc. This file is part of the GNU C Library. Contributed by Ulrich Drepper , 2002. @@ -75,7 +75,7 @@ typedef struct __pthread_internal_slist type is not exposed on purpose. */ typedef union { - struct + struct __pthread_mutex_s { int __lock; unsigned int __count; @@ -86,10 +86,18 @@ typedef union /* KIND must stay at this position in the structure to maintain binary compatibility. */ int __kind; -#if __WORDSIZE != 64 +#if __WORDSIZE == 64 + int __spins; + __pthread_list_t __list; +# define __PTHREAD_MUTEX_HAVE_PREV 1 +#else unsigned int __nusers; + __extension__ union + { + int __spins; + __pthread_slist_t __list; + }; #endif - int __spins; } __data; char __size[__SIZEOF_PTHREAD_MUTEX_T]; long int __align; @@ -151,9 +159,9 @@ typedef union unsigned int __nr_readers_queued; unsigned int __nr_writers_queued; int __writer; - int __pad1; + int __shared; + unsigned long int __pad1; unsigned long int __pad2; - unsigned long int __pad3; /* FLAGS must stay at this position in the structure to maintain binary compatibility. */ unsigned int __flags; @@ -169,7 +177,10 @@ typedef union unsigned int __nr_writers_queued; /* FLAGS must stay at this position in the structure to maintain binary compatibility. */ - unsigned int __flags; + unsigned char __flags; + unsigned char __shared; + unsigned char __pad1; + unsigned char __pad2; int __writer; } __data; # endif @@ -206,4 +217,9 @@ typedef union #endif +#if __WORDSIZE == 32 +/* Extra attributes for the cleanup functions. */ +# define __cleanup_fct_attribute __attribute__ ((__regparm__ (1))) +#endif + #endif /* bits/pthreadtypes.h */ -- cgit v1.2.3