* sysdeps/unix/sysv/linux/kernel-features.h (__ASSUME_PSELECT,

__ASSUME_PPOLL, __ASSUME_ATFCTS, __ASSUME_SET_ROBUST_LIST,
	__ASSUME_UTIMENSAT, __ASSUME_FALLOCATE): Update per-arch conditions
	when each feature was introduced.

	* sysdeps/unix/sysv/linux/dl-vdso.c: Don't include dl-hash.h.
	* sysdeps/unix/sysv/linux/dl-vdso.h: Don't include dl-hash.h if NDEBUG.
	(CHECK_HASH): New macro.
	(PREPARE_VERSION): Use it.

	* sysdeps/unix/sysv/linux/pselect.c (__generic_pselect): Only provide
	prototype if not __ASSUME_PSELECT.
	* sysdeps/unix/sysv/linux/ppoll.c (__generic_ppoll): Only provide
	prototype if not __ASSUME_PPOLL.

	* sysdeps/unix/sysv/linux/dl-osinfo.h (ROUND): #undef after use.

	* sysdeps/unix/clock_settime.c (freq, __pthread_clock_settime,
	hp_timing_settime): Don't define or declare if HANDLED_CPUTIME
	is defined.
This commit is contained in:
Ulrich Drepper 2007-08-14 03:21:23 +00:00
parent 4baf59ada8
commit 22502ea2a7
21 changed files with 466 additions and 104 deletions

View File

@ -1,3 +1,26 @@
2007-08-13 Jakub Jelinek <jakub@redhat.com>
* sysdeps/unix/sysv/linux/kernel-features.h (__ASSUME_PSELECT,
__ASSUME_PPOLL, __ASSUME_ATFCTS, __ASSUME_SET_ROBUST_LIST,
__ASSUME_UTIMENSAT, __ASSUME_FALLOCATE): Update per-arch conditions
when each feature was introduced.
* sysdeps/unix/sysv/linux/dl-vdso.c: Don't include dl-hash.h.
* sysdeps/unix/sysv/linux/dl-vdso.h: Don't include dl-hash.h if NDEBUG.
(CHECK_HASH): New macro.
(PREPARE_VERSION): Use it.
* sysdeps/unix/sysv/linux/pselect.c (__generic_pselect): Only provide
prototype if not __ASSUME_PSELECT.
* sysdeps/unix/sysv/linux/ppoll.c (__generic_ppoll): Only provide
prototype if not __ASSUME_PPOLL.
* sysdeps/unix/sysv/linux/dl-osinfo.h (ROUND): #undef after use.
* sysdeps/unix/clock_settime.c (freq, __pthread_clock_settime,
hp_timing_settime): Don't define or declare if HANDLED_CPUTIME
is defined.
2007-08-13 Ulrich Drepper <drepper@redhat.com> 2007-08-13 Ulrich Drepper <drepper@redhat.com>
* sysdeps/unix/sysv/linux/x86_64/libc-start.c * sysdeps/unix/sysv/linux/x86_64/libc-start.c

View File

@ -1,3 +1,40 @@
2007-08-13 Jakub Jelinek <jakub@redhat.com>
* sysdeps/unix/sysv/linux/i386/lowlevellock.h (__lll_private_flag):
Fix a pasto.
* sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.S
(__pthread_cond_broadcast): Pass LLL_PRIVATE to lll_* and or
FUTEX_PRIVATE_FLAG into SYS_futex op if cv is process private.
Don't use FUTEX_CMP_REQUEUE if dep_mutex is not process private.
* sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S
(__pthread_cond_signal): Pass LLL_PRIVATE to lll_* and or
FUTEX_PRIVATE_FLAG into SYS_futex op if cv is process private.
* sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Include
kernel-features.h.
(__pthread_cond_wait, __condvar_w_cleanup): Pass LLL_PRIVATE to
lll_* and or FUTEX_PRIVATE_FLAG into SYS_futex op if cv is
process private. Switch DW_CFA_advance_loc1 and some
DW_CFA_advance_loc .eh_frame opcodes to DW_CFA_advance_loc4.
* sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S
(__pthread_cond_timedwait, __condvar_tw_cleanup): Pass LLL_PRIVATE to
lll_* and or FUTEX_PRIVATE_FLAG into SYS_futex op if cv is
process private. Switch DW_CFA_advance_loc{1,2} and some
DW_CFA_advance_loc .eh_frame opcodes to DW_CFA_advance_loc4.
* sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_rdlock.S: Use
#ifdef __ASSUME_PRIVATE_FUTEX instead of #if __ASSUME_PRIVATE_FUTEX.
* sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S:
Likewise.
* sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_unlock.S: Likewise.
* sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_wrlock.S: Likewise.
* sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S:
Likewise.
* sysdeps/unix/sysv/linux/x86_64/pthread_cond_broadcast.S
(__pthread_cond_broadcast): Compare %r8 instead of
dep_mutex-cond_*(%rdi) with $-1.
* sysdeps/unix/sysv/linux/x86_64/pthread_cond_signal.S
(__pthread_cond_signal): Xor FUTEX_WAKE_OP with FUTEX_WAKE instead
of oring.
2007-08-13 Ulrich Drepper <drepper@redhat.com> 2007-08-13 Ulrich Drepper <drepper@redhat.com>
* sysdeps/unix/sysv/linux/i386/i786/Implies: New file. * sysdeps/unix/sysv/linux/i386/i786/Implies: New file.

View File

@ -83,11 +83,18 @@ __pthread_cond_broadcast:
je 9f je 9f
/* XXX: The kernel so far doesn't support requeue to PI futex. */ /* XXX: The kernel so far doesn't support requeue to PI futex. */
testl $PI_BIT, MUTEX_KIND(%edi) /* XXX: The kernel only supports FUTEX_CMP_REQUEUE to the same
type of futex (private resp. shared). */
testl $(PI_BIT | PS_BIT), MUTEX_KIND(%edi)
jne 9f jne 9f
/* Wake up all threads. */ /* Wake up all threads. */
movl $FUTEX_CMP_REQUEUE, %ecx #ifdef __ASSUME_PRIVATE_FUTEX
movl $(FUTEX_CMP_REQUEUE|FUTEX_PRIVATE_FLAG), %ecx
#else
movl %gs:PRIVATE_FUTEX, %ecx
orl $FUTEX_CMP_REQUEUE, %ecx
#endif
movl $SYS_futex, %eax movl $SYS_futex, %eax
movl $0x7fffffff, %esi movl $0x7fffffff, %esi
movl $1, %edx movl $1, %edx
@ -132,28 +139,63 @@ __pthread_cond_broadcast:
#else #else
leal cond_lock(%ebx), %edx leal cond_lock(%ebx), %edx
#endif #endif
/* XYZ */ #if (LLL_SHARED-LLL_PRIVATE) > 255
movl $LLL_SHARED, %ecx xorl %ecx, %ecx
#endif
cmpl $-1, dep_mutex(%ebx)
setne %cl
subl $1, %ecx
andl $(LLL_SHARED-LLL_PRIVATE), %ecx
#if LLL_PRIVATE != 0
addl $LLL_PRIVATE, %ecx
#endif
call __lll_lock_wait call __lll_lock_wait
jmp 2b jmp 2b
/* Unlock in loop requires waekup. */ /* Unlock in loop requires waekup. */
5: leal cond_lock-cond_futex(%ebx), %eax 5: leal cond_lock-cond_futex(%ebx), %eax
/* XYZ */ #if (LLL_SHARED-LLL_PRIVATE) > 255
movl $LLL_SHARED, %ecx xorl %ecx, %ecx
#endif
cmpl $-1, dep_mutex-cond_futex(%ebx)
setne %cl
subl $1, %ecx
andl $(LLL_SHARED-LLL_PRIVATE), %ecx
#if LLL_PRIVATE != 0
addl $LLL_PRIVATE, %ecx
#endif
call __lll_unlock_wake call __lll_unlock_wake
jmp 6b jmp 6b
/* Unlock in loop requires waekup. */ /* Unlock in loop requires waekup. */
7: leal cond_lock-cond_futex(%ebx), %eax 7: leal cond_lock-cond_futex(%ebx), %eax
/* XYZ */ #if (LLL_SHARED-LLL_PRIVATE) > 255
movl $LLL_SHARED, %ecx xorl %ecx, %ecx
#endif
cmpl $-1, dep_mutex-cond_futex(%ebx)
setne %cl
subl $1, %ecx
andl $(LLL_SHARED-LLL_PRIVATE), %ecx
#if LLL_PRIVATE != 0
addl $LLL_PRIVATE, %ecx
#endif
call __lll_unlock_wake call __lll_unlock_wake
jmp 8b jmp 8b
9: /* The futex requeue functionality is not available. */ 9: /* The futex requeue functionality is not available. */
movl $0x7fffffff, %edx movl $0x7fffffff, %edx
movl $FUTEX_WAKE, %ecx #if FUTEX_PRIVATE_FLAG > 255
xorl %ecx, %ecx
#endif
cmpl $-1, dep_mutex-cond_futex(%ebx)
sete %cl
subl $1, %ecx
#ifdef __ASSUME_PRIVATE_FUTEX
andl $FUTEX_PRIVATE_FLAG, %ecx
#else
andl %gs:PRIVATE_FUTEX, %ecx
#endif
addl $FUTEX_WAKE, %ecx
movl $SYS_futex, %eax movl $SYS_futex, %eax
ENTER_KERNEL ENTER_KERNEL
jmp 10b jmp 10b

View File

@ -70,7 +70,18 @@ __pthread_cond_signal:
/* Wake up one thread. */ /* Wake up one thread. */
pushl %esi pushl %esi
pushl %ebp pushl %ebp
movl $FUTEX_WAKE_OP, %ecx #if FUTEX_PRIVATE_FLAG > 255
xorl %ecx, %ecx
#endif
cmpl $-1, dep_mutex-cond_futex(%ebx)
sete %cl
subl $1, %ecx
#ifdef __ASSUME_PRIVATE_FUTEX
andl $FUTEX_PRIVATE_FLAG, %ecx
#else
andl %gs:PRIVATE_FUTEX, %ecx
#endif
addl $FUTEX_WAKE_OP, %ecx
movl $SYS_futex, %eax movl $SYS_futex, %eax
movl $1, %edx movl $1, %edx
movl $1, %esi movl $1, %esi
@ -92,7 +103,9 @@ __pthread_cond_signal:
popl %ebx popl %ebx
ret ret
7: movl $FUTEX_WAKE, %ecx 7: /* %ecx should be either FUTEX_WAKE_OP or
FUTEX_WAKE_OP|FUTEX_PRIVATE_FLAG from the previous syscall. */
xorl $(FUTEX_WAKE ^ FUTEX_WAKE_OP), %ecx
movl $SYS_futex, %eax movl $SYS_futex, %eax
/* %edx should be 1 already from $FUTEX_WAKE_OP syscall. /* %edx should be 1 already from $FUTEX_WAKE_OP syscall.
movl $1, %edx */ movl $1, %edx */
@ -106,8 +119,16 @@ __pthread_cond_signal:
/* Unlock in loop requires wakeup. */ /* Unlock in loop requires wakeup. */
5: movl %edi, %eax 5: movl %edi, %eax
/* XYZ */ #if (LLL_SHARED-LLL_PRIVATE) > 255
movl $LLL_SHARED, %ecx xorl %ecx, %ecx
#endif
cmpl $-1, dep_mutex-cond_futex(%ebx)
setne %cl
subl $1, %ecx
andl $(LLL_SHARED-LLL_PRIVATE), %ecx
#if LLL_PRIVATE != 0
addl $LLL_PRIVATE, %ecx
#endif
call __lll_unlock_wake call __lll_unlock_wake
jmp 6b jmp 6b
@ -118,8 +139,16 @@ __pthread_cond_signal:
#else #else
leal cond_lock(%edi), %edx leal cond_lock(%edi), %edx
#endif #endif
/* XYZ */ #if (LLL_SHARED-LLL_PRIVATE) > 255
movl $LLL_SHARED, %ecx xorl %ecx, %ecx
#endif
cmpl $-1, dep_mutex(%edi)
setne %cl
subl $1, %ecx
andl $(LLL_SHARED-LLL_PRIVATE), %ecx
#if LLL_PRIVATE != 0
addl $LLL_PRIVATE, %ecx
#endif
call __lll_lock_wait call __lll_lock_wait
jmp 2b jmp 2b

View File

@ -158,7 +158,20 @@ __pthread_cond_timedwait:
movl %eax, (%esp) movl %eax, (%esp)
leal 4(%esp), %esi leal 4(%esp), %esi
xorl %ecx, %ecx /* movl $FUTEX_WAIT, %ecx */ #if FUTEX_PRIVATE_FLAG > 255
xorl %ecx, %ecx
#endif
cmpl $-1, dep_mutex(%ebx)
sete %cl
subl $1, %ecx
#ifdef __ASSUME_PRIVATE_FUTEX
andl $FUTEX_PRIVATE_FLAG, %ecx
#else
andl %gs:PRIVATE_FUTEX, %ecx
#endif
#if FUTEX_WAIT != 0
addl $FUTEX_WAIT, %ecx
#endif
movl %edi, %edx movl %edi, %edx
addl $cond_futex, %ebx addl $cond_futex, %ebx
.Ladd_cond_futex: .Ladd_cond_futex:
@ -232,7 +245,18 @@ __pthread_cond_timedwait:
addl $cond_nwaiters, %ebx addl $cond_nwaiters, %ebx
movl $SYS_futex, %eax movl $SYS_futex, %eax
movl $FUTEX_WAKE, %ecx #if FUTEX_PRIVATE_FLAG > 255
xorl %ecx, %ecx
#endif
cmpl $-1, dep_mutex-cond_nwaiters(%ebx)
sete %cl
subl $1, %ecx
#ifdef __ASSUME_PRIVATE_FUTEX
andl $FUTEX_PRIVATE_FLAG, %ecx
#else
andl %gs:PRIVATE_FUTEX, %ecx
#endif
addl $FUTEX_WAKE, %ecx
movl $1, %edx movl $1, %edx
ENTER_KERNEL ENTER_KERNEL
subl $cond_nwaiters, %ebx subl $cond_nwaiters, %ebx
@ -280,8 +304,16 @@ __pthread_cond_timedwait:
#else #else
leal cond_lock(%ebx), %edx leal cond_lock(%ebx), %edx
#endif #endif
/* XYZ */ #if (LLL_SHARED-LLL_PRIVATE) > 255
movl $LLL_SHARED, %ecx xorl %ecx, %ecx
#endif
cmpl $-1, dep_mutex(%ebx)
setne %cl
subl $1, %ecx
andl $(LLL_SHARED-LLL_PRIVATE), %ecx
#if LLL_PRIVATE != 0
addl $LLL_PRIVATE, %ecx
#endif
call __lll_lock_wait call __lll_lock_wait
jmp 2b jmp 2b
@ -293,8 +325,16 @@ __pthread_cond_timedwait:
#else #else
leal cond_lock(%ebx), %eax leal cond_lock(%ebx), %eax
#endif #endif
/* XYZ */ #if (LLL_SHARED-LLL_PRIVATE) > 255
movl $LLL_SHARED, %ecx xorl %ecx, %ecx
#endif
cmpl $-1, dep_mutex(%ebx)
setne %cl
subl $1, %ecx
andl $(LLL_SHARED-LLL_PRIVATE), %ecx
#if LLL_PRIVATE != 0
addl $LLL_PRIVATE, %ecx
#endif
call __lll_unlock_wake call __lll_unlock_wake
jmp 4b jmp 4b
@ -305,8 +345,16 @@ __pthread_cond_timedwait:
#else #else
leal cond_lock(%ebx), %edx leal cond_lock(%ebx), %edx
#endif #endif
/* XYZ */ #if (LLL_SHARED-LLL_PRIVATE) > 255
movl $LLL_SHARED, %ecx xorl %ecx, %ecx
#endif
cmpl $-1, dep_mutex(%ebx)
setne %cl
subl $1, %ecx
andl $(LLL_SHARED-LLL_PRIVATE), %ecx
#if LLL_PRIVATE != 0
addl $LLL_PRIVATE, %ecx
#endif
call __lll_lock_wait call __lll_lock_wait
jmp 6b jmp 6b
@ -317,8 +365,16 @@ __pthread_cond_timedwait:
#else #else
leal cond_lock(%ebx), %eax leal cond_lock(%ebx), %eax
#endif #endif
/* XYZ */ #if (LLL_SHARED-LLL_PRIVATE) > 255
movl $LLL_SHARED, %ecx xorl %ecx, %ecx
#endif
cmpl $-1, dep_mutex(%ebx)
setne %cl
subl $1, %ecx
andl $(LLL_SHARED-LLL_PRIVATE), %ecx
#if LLL_PRIVATE != 0
addl $LLL_PRIVATE, %ecx
#endif
call __lll_unlock_wake call __lll_unlock_wake
jmp 11b jmp 11b
@ -339,8 +395,16 @@ __pthread_cond_timedwait:
#else #else
leal cond_lock(%ebx), %eax leal cond_lock(%ebx), %eax
#endif #endif
/* XYZ */ #if (LLL_SHARED-LLL_PRIVATE) > 255
movl $LLL_SHARED, %ecx xorl %ecx, %ecx
#endif
cmpl $-1, dep_mutex(%ebx)
setne %cl
subl $1, %ecx
andl $(LLL_SHARED-LLL_PRIVATE), %ecx
#if LLL_PRIVATE != 0
addl $LLL_PRIVATE, %ecx
#endif
call __lll_unlock_wake call __lll_unlock_wake
movl %esi, %eax movl %esi, %eax
@ -401,8 +465,16 @@ __condvar_tw_cleanup:
#else #else
leal cond_lock(%ebx), %edx leal cond_lock(%ebx), %edx
#endif #endif
/* XYZ */ #if (LLL_SHARED-LLL_PRIVATE) > 255
movl $LLL_SHARED, %ecx xorl %ecx, %ecx
#endif
cmpl $-1, dep_mutex(%ebx)
setne %cl
subl $1, %ecx
andl $(LLL_SHARED-LLL_PRIVATE), %ecx
#if LLL_PRIVATE != 0
addl $LLL_PRIVATE, %ecx
#endif
call __lll_lock_wait call __lll_lock_wait
1: movl broadcast_seq(%ebx), %eax 1: movl broadcast_seq(%ebx), %eax
@ -441,7 +513,18 @@ __condvar_tw_cleanup:
addl $cond_nwaiters, %ebx addl $cond_nwaiters, %ebx
movl $SYS_futex, %eax movl $SYS_futex, %eax
movl $FUTEX_WAKE, %ecx #if FUTEX_PRIVATE_FLAG > 255
xorl %ecx, %ecx
#endif
cmpl $-1, dep_mutex-cond_nwaiters(%ebx)
sete %cl
subl $1, %ecx
#ifdef __ASSUME_PRIVATE_FUTEX
andl $FUTEX_PRIVATE_FLAG, %ecx
#else
andl %gs:PRIVATE_FUTEX, %ecx
#endif
addl $FUTEX_WAKE, %ecx
movl $1, %edx movl $1, %edx
ENTER_KERNEL ENTER_KERNEL
subl $cond_nwaiters, %ebx subl $cond_nwaiters, %ebx
@ -460,15 +543,34 @@ __condvar_tw_cleanup:
#else #else
leal cond_lock(%ebx), %eax leal cond_lock(%ebx), %eax
#endif #endif
/* XYZ */ #if (LLL_SHARED-LLL_PRIVATE) > 255
movl $LLL_SHARED, %ecx xorl %ecx, %ecx
#endif
cmpl $-1, dep_mutex(%ebx)
setne %cl
subl $1, %ecx
andl $(LLL_SHARED-LLL_PRIVATE), %ecx
#if LLL_PRIVATE != 0
addl $LLL_PRIVATE, %ecx
#endif
call __lll_unlock_wake call __lll_unlock_wake
/* Wake up all waiters to make sure no signal gets lost. */ /* Wake up all waiters to make sure no signal gets lost. */
2: testl %edi, %edi 2: testl %edi, %edi
jnz 5f jnz 5f
addl $cond_futex, %ebx addl $cond_futex, %ebx
movl $FUTEX_WAKE, %ecx #if FUTEX_PRIVATE_FLAG > 255
xorl %ecx, %ecx
#endif
cmpl $-1, dep_mutex-cond_futex(%ebx)
sete %cl
subl $1, %ecx
#ifdef __ASSUME_PRIVATE_FUTEX
andl $FUTEX_PRIVATE_FLAG, %ecx
#else
andl %gs:PRIVATE_FUTEX, %ecx
#endif
addl $FUTEX_WAKE, %ecx
movl $SYS_futex, %eax movl $SYS_futex, %eax
movl $0x7fffffff, %edx movl $0x7fffffff, %edx
ENTER_KERNEL ENTER_KERNEL
@ -588,12 +690,12 @@ __condvar_tw_cleanup:
.uleb128 20 .uleb128 20
.byte 0x83 # DW_CFA_offset %ebx .byte 0x83 # DW_CFA_offset %ebx
.uleb128 5 .uleb128 5
.byte 2 # DW_CFA_advance_loc1 .byte 4 # DW_CFA_advance_loc4
.byte .Lsubl-.Lpush_ebx .4byte .Lsubl-.Lpush_ebx
.byte 14 # DW_CFA_def_cfa_offset .byte 14 # DW_CFA_def_cfa_offset
.uleb128 20+FRAME_SIZE .uleb128 20+FRAME_SIZE
.byte 3 # DW_CFA_advance_loc2 .byte 4 # DW_CFA_advance_loc4
.2byte .Laddl-.Lsubl .4byte .Laddl-.Lsubl
.byte 14 # DW_CFA_def_cfa_offset .byte 14 # DW_CFA_def_cfa_offset
.uleb128 20 .uleb128 20
.byte 0x40+.Lpop_ebx-.Laddl # DW_CFA_advance_loc+N .byte 0x40+.Lpop_ebx-.Laddl # DW_CFA_advance_loc+N
@ -615,7 +717,8 @@ __condvar_tw_cleanup:
.byte 0x40+.LSbl1-.Lpop_edi # DW_CFA_advance_loc+N .byte 0x40+.LSbl1-.Lpop_edi # DW_CFA_advance_loc+N
.byte 14 # DW_CFA_def_cfa_offset .byte 14 # DW_CFA_def_cfa_offset
.uleb128 20 .uleb128 20
.byte 0x40+.LSbl2-.LSbl1 # DW_CFA_advance_loc+N .byte 4 # DW_CFA_advance_loc4
.4byte .LSbl2-.LSbl1
.byte 14 # DW_CFA_def_cfa_offset .byte 14 # DW_CFA_def_cfa_offset
.uleb128 20+FRAME_SIZE .uleb128 20+FRAME_SIZE
.byte 0x85 # DW_CFA_offset %ebp .byte 0x85 # DW_CFA_offset %ebp
@ -626,14 +729,15 @@ __condvar_tw_cleanup:
.uleb128 4 .uleb128 4
.byte 0x83 # DW_CFA_offset %ebx .byte 0x83 # DW_CFA_offset %ebx
.uleb128 5 .uleb128 5
.byte 0x40+.LSbl3-.LSbl2 # DW_CFA_advance_loc+N .byte 4 # DW_CFA_advance_loc4
.4byte .LSbl3-.LSbl2
.byte 14 # DW_CFA_def_cfa_offset .byte 14 # DW_CFA_def_cfa_offset
.uleb128 20 .uleb128 20
#if defined __NR_clock_gettime && !defined __ASSUME_POSIX_TIMERS
.byte 0x40+.LSbl4-.LSbl3 # DW_CFA_advance_loc+N
#else
.byte 4 # DW_CFA_advance_loc4 .byte 4 # DW_CFA_advance_loc4
.long .LSbl5-.LSbl3 #if defined __NR_clock_gettime && !defined __ASSUME_POSIX_TIMERS
.4byte .LSbl4-.LSbl3
#else
.4byte .LSbl5-.LSbl3
#endif #endif
.byte 14 # DW_CFA_def_cfa_offset .byte 14 # DW_CFA_def_cfa_offset
.uleb128 20+FRAME_SIZE .uleb128 20+FRAME_SIZE

View File

@ -22,6 +22,7 @@
#include <lowlevellock.h> #include <lowlevellock.h>
#include <lowlevelcond.h> #include <lowlevelcond.h>
#include <tcb-offsets.h> #include <tcb-offsets.h>
#include <kernel-features.h>
.text .text
@ -100,7 +101,20 @@ __pthread_cond_wait:
4: call __pthread_enable_asynccancel 4: call __pthread_enable_asynccancel
movl %eax, (%esp) movl %eax, (%esp)
movl %esi, %ecx /* movl $FUTEX_WAIT, %ecx */ #if FUTEX_PRIVATE_FLAG > 255
xorl %ecx, %ecx
#endif
cmpl $-1, dep_mutex(%ebx)
sete %cl
subl $1, %ecx
#ifdef __ASSUME_PRIVATE_FUTEX
andl $FUTEX_PRIVATE_FLAG, %ecx
#else
andl %gs:PRIVATE_FUTEX, %ecx
#endif
#if FUTEX_WAIT != 0
addl $FUTEX_WAIT, %ecx
#endif
movl %edi, %edx movl %edi, %edx
addl $cond_futex, %ebx addl $cond_futex, %ebx
.Ladd_cond_futex: .Ladd_cond_futex:
@ -161,7 +175,18 @@ __pthread_cond_wait:
addl $cond_nwaiters, %ebx addl $cond_nwaiters, %ebx
movl $SYS_futex, %eax movl $SYS_futex, %eax
movl $FUTEX_WAKE, %ecx #if FUTEX_PRIVATE_FLAG > 255
xorl %ecx, %ecx
#endif
cmpl $-1, dep_mutex-cond_nwaiters(%ebx)
sete %cl
subl $1, %ecx
#ifdef __ASSUME_PRIVATE_FUTEX
andl $FUTEX_PRIVATE_FLAG, %ecx
#else
andl %gs:PRIVATE_FUTEX, %ecx
#endif
addl $FUTEX_WAKE, %ecx
movl $1, %edx movl $1, %edx
ENTER_KERNEL ENTER_KERNEL
subl $cond_nwaiters, %ebx subl $cond_nwaiters, %ebx
@ -197,8 +222,16 @@ __pthread_cond_wait:
#else #else
leal cond_lock(%ebx), %edx leal cond_lock(%ebx), %edx
#endif #endif
/* XYZ */ #if (LLL_SHARED-LLL_PRIVATE) > 255
movl $LLL_SHARED, %ecx xorl %ecx, %ecx
#endif
cmpl $-1, dep_mutex(%ebx)
setne %cl
subl $1, %ecx
andl $(LLL_SHARED-LLL_PRIVATE), %ecx
#if LLL_PRIVATE != 0
addl $LLL_PRIVATE, %ecx
#endif
call __lll_lock_wait call __lll_lock_wait
jmp 2b jmp 2b
@ -210,8 +243,16 @@ __pthread_cond_wait:
#else #else
leal cond_lock(%ebx), %eax leal cond_lock(%ebx), %eax
#endif #endif
/* XYZ */ #if (LLL_SHARED-LLL_PRIVATE) > 255
movl $LLL_SHARED, %ecx xorl %ecx, %ecx
#endif
cmpl $-1, dep_mutex(%ebx)
setne %cl
subl $1, %ecx
andl $(LLL_SHARED-LLL_PRIVATE), %ecx
#if LLL_PRIVATE != 0
addl $LLL_PRIVATE, %ecx
#endif
call __lll_unlock_wake call __lll_unlock_wake
jmp 4b jmp 4b
@ -222,8 +263,16 @@ __pthread_cond_wait:
#else #else
leal cond_lock(%ebx), %edx leal cond_lock(%ebx), %edx
#endif #endif
/* XYZ */ #if (LLL_SHARED-LLL_PRIVATE) > 255
movl $LLL_SHARED, %ecx xorl %ecx, %ecx
#endif
cmpl $-1, dep_mutex(%ebx)
setne %cl
subl $1, %ecx
andl $(LLL_SHARED-LLL_PRIVATE), %ecx
#if LLL_PRIVATE != 0
addl $LLL_PRIVATE, %ecx
#endif
call __lll_lock_wait call __lll_lock_wait
jmp 6b jmp 6b
@ -234,8 +283,16 @@ __pthread_cond_wait:
#else #else
leal cond_lock(%ebx), %eax leal cond_lock(%ebx), %eax
#endif #endif
/* XYZ */ #if (LLL_SHARED-LLL_PRIVATE) > 255
movl $LLL_SHARED, %ecx xorl %ecx, %ecx
#endif
cmpl $-1, dep_mutex(%ebx)
setne %cl
subl $1, %ecx
andl $(LLL_SHARED-LLL_PRIVATE), %ecx
#if LLL_PRIVATE != 0
addl $LLL_PRIVATE, %ecx
#endif
call __lll_unlock_wake call __lll_unlock_wake
jmp 11b jmp 11b
@ -256,8 +313,16 @@ __pthread_cond_wait:
#else #else
leal cond_lock(%ebx), %eax leal cond_lock(%ebx), %eax
#endif #endif
/* XYZ */ #if (LLL_SHARED-LLL_PRIVATE) > 255
movl $LLL_SHARED, %ecx xorl %ecx, %ecx
#endif
cmpl $-1, dep_mutex(%ebx)
setne %cl
subl $1, %ecx
andl $(LLL_SHARED-LLL_PRIVATE), %ecx
#if LLL_PRIVATE != 0
addl $LLL_PRIVATE, %ecx
#endif
call __lll_unlock_wake call __lll_unlock_wake
movl %esi, %eax movl %esi, %eax
@ -292,8 +357,16 @@ __condvar_w_cleanup:
#else #else
leal cond_lock(%ebx), %edx leal cond_lock(%ebx), %edx
#endif #endif
/* XYZ */ #if (LLL_SHARED-LLL_PRIVATE) > 255
movl $LLL_SHARED, %ecx xorl %ecx, %ecx
#endif
cmpl $-1, dep_mutex(%ebx)
setne %cl
subl $1, %ecx
andl $(LLL_SHARED-LLL_PRIVATE), %ecx
#if LLL_PRIVATE != 0
addl $LLL_PRIVATE, %ecx
#endif
call __lll_lock_wait call __lll_lock_wait
1: movl broadcast_seq(%ebx), %eax 1: movl broadcast_seq(%ebx), %eax
@ -332,7 +405,18 @@ __condvar_w_cleanup:
addl $cond_nwaiters, %ebx addl $cond_nwaiters, %ebx
movl $SYS_futex, %eax movl $SYS_futex, %eax
movl $FUTEX_WAKE, %ecx #if FUTEX_PRIVATE_FLAG > 255
xorl %ecx, %ecx
#endif
cmpl $-1, dep_mutex-cond_nwaiters(%ebx)
sete %cl
subl $1, %ecx
#ifdef __ASSUME_PRIVATE_FUTEX
andl $FUTEX_PRIVATE_FLAG, %ecx
#else
andl %gs:PRIVATE_FUTEX, %ecx
#endif
addl $FUTEX_WAKE, %ecx
movl $1, %edx movl $1, %edx
ENTER_KERNEL ENTER_KERNEL
subl $cond_nwaiters, %ebx subl $cond_nwaiters, %ebx
@ -351,15 +435,34 @@ __condvar_w_cleanup:
#else #else
leal cond_lock(%ebx), %eax leal cond_lock(%ebx), %eax
#endif #endif
/* XYZ */ #if (LLL_SHARED-LLL_PRIVATE) > 255
movl $LLL_SHARED, %ecx xorl %ecx, %ecx
#endif
cmpl $-1, dep_mutex(%ebx)
setne %cl
subl $1, %ecx
andl $(LLL_SHARED-LLL_PRIVATE), %ecx
#if LLL_PRIVATE != 0
addl $LLL_PRIVATE, %ecx
#endif
call __lll_unlock_wake call __lll_unlock_wake
/* Wake up all waiters to make sure no signal gets lost. */ /* Wake up all waiters to make sure no signal gets lost. */
2: testl %edi, %edi 2: testl %edi, %edi
jnz 5f jnz 5f
addl $cond_futex, %ebx addl $cond_futex, %ebx
movl $FUTEX_WAKE, %ecx #if FUTEX_PRIVATE_FLAG > 255
xorl %ecx, %ecx
#endif
cmpl $-1, dep_mutex-cond_futex(%ebx)
sete %cl
subl $1, %ecx
#ifdef __ASSUME_PRIVATE_FUTEX
andl $FUTEX_PRIVATE_FLAG, %ecx
#else
andl %gs:PRIVATE_FUTEX, %ecx
#endif
addl $FUTEX_WAKE, %ecx
movl $SYS_futex, %eax movl $SYS_futex, %eax
movl $0x7fffffff, %edx movl $0x7fffffff, %edx
ENTER_KERNEL ENTER_KERNEL
@ -473,12 +576,12 @@ __condvar_w_cleanup:
.uleb128 16 .uleb128 16
.byte 0x83 # DW_CFA_offset %ebx .byte 0x83 # DW_CFA_offset %ebx
.uleb128 4 .uleb128 4
.byte 2 # DW_CFA_advance_loc1 .byte 4 # DW_CFA_advance_loc4
.byte .Lsubl-.Lpush_ebx .4byte .Lsubl-.Lpush_ebx
.byte 14 # DW_CFA_def_cfa_offset .byte 14 # DW_CFA_def_cfa_offset
.uleb128 16+FRAME_SIZE .uleb128 16+FRAME_SIZE
.byte 2 # DW_CFA_advance_loc1 .byte 4 # DW_CFA_advance_loc4
.byte .Laddl-.Lsubl .4byte .Laddl-.Lsubl
.byte 14 # DW_CFA_def_cfa_offset .byte 14 # DW_CFA_def_cfa_offset
.uleb128 16 .uleb128 16
.byte 0x40+ .Lpop_ebx-.Laddl # DW_CFA_advance_loc+N .byte 0x40+ .Lpop_ebx-.Laddl # DW_CFA_advance_loc+N
@ -502,13 +605,16 @@ __condvar_w_cleanup:
.uleb128 3 .uleb128 3
.byte 0x83 # DW_CFA_offset %ebx .byte 0x83 # DW_CFA_offset %ebx
.uleb128 4 .uleb128 4
.byte 0x40+.LSbl2-.LSbl1 # DW_CFA_advance_loc+N .byte 4 # DW_CFA_advance_loc4
.4byte .LSbl2-.LSbl1
.byte 14 # DW_CFA_def_cfa_offset .byte 14 # DW_CFA_def_cfa_offset
.uleb128 16+FRAME_SIZE .uleb128 16+FRAME_SIZE
.byte 0x40+.LSbl3-.LSbl2 # DW_CFA_advance_loc+N .byte 4 # DW_CFA_advance_loc4
.4byte .LSbl3-.LSbl2
.byte 14 # DW_CFA_def_cfa_offset .byte 14 # DW_CFA_def_cfa_offset
.uleb128 16 .uleb128 16
.byte 0x40+.LSbl4-.LSbl3 # DW_CFA_advance_loc+N .byte 4 # DW_CFA_advance_loc4
.4byte .LSbl4-.LSbl3
.byte 14 # DW_CFA_def_cfa_offset .byte 14 # DW_CFA_def_cfa_offset
.uleb128 16+FRAME_SIZE .uleb128 16+FRAME_SIZE
.align 4 .align 4

View File

@ -69,7 +69,7 @@ __pthread_rwlock_rdlock:
jne 10f jne 10f
11: 11:
#if __ASSUME_PRIVATE_FUTEX #ifdef __ASSUME_PRIVATE_FUTEX
movzbl PSHARED(%ebx), %ecx movzbl PSHARED(%ebx), %ecx
xorl $FUTEX_PRIVATE_FLAG|FUTEX_WAIT, %ecx xorl $FUTEX_PRIVATE_FLAG|FUTEX_WAIT, %ecx
#else #else

View File

@ -100,7 +100,7 @@ pthread_rwlock_timedrdlock:
movl %edx, 4(%esp) movl %edx, 4(%esp)
movl %esi, %edx movl %esi, %edx
#if __ASSUME_PRIVATE_FUTEX #ifdef __ASSUME_PRIVATE_FUTEX
movzbl PSHARED(%ebp), %ecx movzbl PSHARED(%ebp), %ecx
xorl $FUTEX_PRIVATE_FLAG|FUTEX_WAIT, %ecx xorl $FUTEX_PRIVATE_FLAG|FUTEX_WAIT, %ecx
#else #else

View File

@ -98,7 +98,7 @@ pthread_rwlock_timedwrlock:
movl %edx, 4(%esp) movl %edx, 4(%esp)
movl %esi, %edx movl %esi, %edx
#if __ASSUME_PRIVATE_FUTEX #ifdef __ASSUME_PRIVATE_FUTEX
movzbl PSHARED(%ebp), %ecx movzbl PSHARED(%ebp), %ecx
xorl $FUTEX_PRIVATE_FLAG|FUTEX_WAIT, %ecx xorl $FUTEX_PRIVATE_FLAG|FUTEX_WAIT, %ecx
#else #else

View File

@ -74,7 +74,7 @@ __pthread_rwlock_unlock:
jne 7f jne 7f
8: 8:
#if __ASSUME_PRIVATE_FUTEX #ifdef __ASSUME_PRIVATE_FUTEX
movzbl PSHARED(%edi), %ecx movzbl PSHARED(%edi), %ecx
xorl $FUTEX_PRIVATE_FLAG|FUTEX_WAKE, %ecx xorl $FUTEX_PRIVATE_FLAG|FUTEX_WAKE, %ecx
#else #else

View File

@ -67,7 +67,7 @@ __pthread_rwlock_wrlock:
jne 10f jne 10f
11: 11:
#if __ASSUME_PRIVATE_FUTEX #ifdef __ASSUME_PRIVATE_FUTEX
movzbl PSHARED(%ebx), %ecx movzbl PSHARED(%ebx), %ecx
xorl $FUTEX_PRIVATE_FLAG|FUTEX_WAIT, %ecx xorl $FUTEX_PRIVATE_FLAG|FUTEX_WAIT, %ecx
#else #else

View File

@ -83,7 +83,7 @@
? ((fl) | THREAD_GETMEM (THREAD_SELF, header.private_futex)) \ ? ((fl) | THREAD_GETMEM (THREAD_SELF, header.private_futex)) \
: (fl)) \ : (fl)) \
: ({ unsigned int __fl = ((private) ^ FUTEX_PRIVATE_FLAG); \ : ({ unsigned int __fl = ((private) ^ FUTEX_PRIVATE_FLAG); \
asm ("andl %%fs:%P1, %0" : "+r" (__fl) \ asm ("andl %%gs:%P1, %0" : "+r" (__fl) \
: "i" (offsetof (struct pthread, header.private_futex))); \ : "i" (offsetof (struct pthread, header.private_futex))); \
__fl | (fl); })) __fl | (fl); }))
# endif # endif

View File

@ -132,7 +132,7 @@ __pthread_cond_broadcast:
/* Unlock in loop requires wakeup. */ /* Unlock in loop requires wakeup. */
7: addq $cond_lock-cond_futex, %rdi 7: addq $cond_lock-cond_futex, %rdi
cmpq $-1, dep_mutex-cond_lock(%rdi) cmpq $-1, %r8
movl $LLL_PRIVATE, %eax movl $LLL_PRIVATE, %eax
movl $LLL_SHARED, %esi movl $LLL_SHARED, %esi
cmovne %eax, %esi cmovne %eax, %esi
@ -141,7 +141,7 @@ __pthread_cond_broadcast:
jmp 8b jmp 8b
9: /* The futex requeue functionality is not available. */ 9: /* The futex requeue functionality is not available. */
cmpq $-1, dep_mutex-cond_futex(%rdi) cmpq $-1, %r8
movl $0x7fffffff, %edx movl $0x7fffffff, %edx
#ifdef __ASSUME_PRIVATE_FUTEX #ifdef __ASSUME_PRIVATE_FUTEX
movl $FUTEX_WAKE, %eax movl $FUTEX_WAKE, %eax

View File

@ -87,7 +87,7 @@ __pthread_cond_signal:
7: /* %esi should be either FUTEX_WAKE_OP or 7: /* %esi should be either FUTEX_WAKE_OP or
FUTEX_WAKE_OP|FUTEX_PRIVATE_FLAG from the previous syscall. */ FUTEX_WAKE_OP|FUTEX_PRIVATE_FLAG from the previous syscall. */
xorl $(FUTEX_WAKE | FUTEX_WAKE_OP), %esi xorl $(FUTEX_WAKE ^ FUTEX_WAKE_OP), %esi
movl $SYS_futex, %eax movl $SYS_futex, %eax
/* %rdx should be 1 already from $FUTEX_WAKE_OP syscall. /* %rdx should be 1 already from $FUTEX_WAKE_OP syscall.
movl $1, %edx */ movl $1, %edx */

View File

@ -1,4 +1,4 @@
/* Copyright (C) 1999-2004, 2006 Free Software Foundation, Inc. /* Copyright (C) 1999-2004, 2006, 2007 Free Software Foundation, Inc.
This file is part of the GNU C Library. This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or The GNU C Library is free software; you can redistribute it and/or
@ -23,7 +23,7 @@
#include <ldsodefs.h> #include <ldsodefs.h>
#if HP_TIMING_AVAIL #if HP_TIMING_AVAIL && !defined HANDLED_CPUTIME
/* Clock frequency of the processor. We make it a 64-bit variable /* Clock frequency of the processor. We make it a 64-bit variable
because some jokers are already playing with processors with more because some jokers are already playing with processors with more
than 4GHz. */ than 4GHz. */
@ -33,10 +33,8 @@ static hp_timing_t freq;
/* This function is defined in the thread library. */ /* This function is defined in the thread library. */
extern void __pthread_clock_settime (clockid_t clock_id, hp_timing_t offset) extern void __pthread_clock_settime (clockid_t clock_id, hp_timing_t offset)
__attribute__ ((__weak__)); __attribute__ ((__weak__));
#endif
#if HP_TIMING_AVAIL
static int static int
hp_timing_settime (clockid_t clock_id, const struct timespec *tp) hp_timing_settime (clockid_t clock_id, const struct timespec *tp)
{ {

View File

@ -71,6 +71,7 @@ _dl_discover_osversion (void)
#define ROUND(len) (((len) + sizeof note->n_type - 1) & -sizeof note->n_type) #define ROUND(len) (((len) + sizeof note->n_type - 1) & -sizeof note->n_type)
note = ((const void *) (note + 1) note = ((const void *) (note + 1)
+ ROUND (note->n_namesz) + ROUND (note->n_descsz)); + ROUND (note->n_namesz) + ROUND (note->n_descsz));
#undef ROUND
} }
} }
} }

View File

@ -18,7 +18,6 @@
02111-1307 USA. */ 02111-1307 USA. */
#include "config.h" #include "config.h"
#include <dl-hash.h>
#include <ldsodefs.h> #include <ldsodefs.h>

View File

@ -21,9 +21,14 @@
#define _DL_VDSO_H 1 #define _DL_VDSO_H 1
#include <assert.h> #include <assert.h>
#include <dl-hash.h>
#include <ldsodefs.h> #include <ldsodefs.h>
#ifdef NDEBUG
# define CHECK_HASH(var) do {} while (0)
#else
# include <dl-hash.h>
# define CHECK_HASH(var) assert (var.hash == _dl_elf_hash (var.name))
#endif
/* Create version number record for lookup. */ /* Create version number record for lookup. */
#define PREPARE_VERSION(var, vname, vhash) \ #define PREPARE_VERSION(var, vname, vhash) \
@ -31,7 +36,7 @@
var.name = vname; \ var.name = vname; \
var.hidden = 1; \ var.hidden = 1; \
var.hash = vhash; \ var.hash = vhash; \
assert (var.hash == _dl_elf_hash (vname)); \ CHECK_HASH (var); \
/* We don't have a specific file where the symbol can be found. */ \ /* We don't have a specific file where the symbol can be found. */ \
var.filename = NULL var.filename = NULL

View File

@ -428,29 +428,37 @@
# define __ASSUME_TMPFS_NAME 1 # define __ASSUME_TMPFS_NAME 1
#endif #endif
/* pselect was introduced just after 2.6.16-rc1. Due to the way the /* pselect/ppoll were introduced just after 2.6.16-rc1. Due to the way
kernel versions are advertised we can only rely on 2.6.17 to have the kernel versions are advertised we can only rely on 2.6.17 to have
the code. */ the code. On x86_64 and SH this appeared first in 2.6.19-rc1,
#if __LINUX_KERNEL_VERSION >= 0x020611 && !defined __x86_64__ on ia64 in 2.6.22-rc1 and on alpha just after 2.6.22-rc1. */
#if __LINUX_KERNEL_VERSION >= 0x020611 \
&& ((!defined __x86_64__ && !defined __sh__ && !defined __ia64__ \
&& !defined __alpha__) \
|| (__LINUX_KERNEL_VERSION >= 0x020613 \
&& (defined __x86_64__ || defined __sh__)) \
|| (__LINUX_KERNEL_VERSION >= 0x020616 && defined __ia64__) \
|| (__LINUX_KERNEL_VERSION >= 0x020617 && defined __alpha__))
# define __ASSUME_PSELECT 1 # define __ASSUME_PSELECT 1
#endif
/* ppoll was introduced just after 2.6.16-rc1. Due to the way the
kernel versions are advertised we can only rely on 2.6.17 to have
the code. */
#if __LINUX_KERNEL_VERSION >= 0x020611 && !defined __x86_64__
# define __ASSUME_PPOLL 1 # define __ASSUME_PPOLL 1
#endif #endif
/* The *at syscalls were introduced just after 2.6.16-rc1. Due to the way the /* The *at syscalls were introduced just after 2.6.16-rc1. Due to the way the
kernel versions are advertised we can only rely on 2.6.17 to have kernel versions are advertised we can only rely on 2.6.17 to have
the code. */ the code. On PPC they were introduced in 2.6.17-rc1, on SH in 2.6.19-rc1
#if __LINUX_KERNEL_VERSION >= 0x020611 and on Alpha just after 2.6.22-rc1. */
#if __LINUX_KERNEL_VERSION >= 0x020611 \
&& ((!defined __sh__ && !defined __alpha__) \
|| (__LINUX_KERNEL_VERSION >= 0x020613 && defined __sh__) \
|| (__LINUX_KERNEL_VERSION >= 0x020617 && defined __alpha__))
# define __ASSUME_ATFCTS 1 # define __ASSUME_ATFCTS 1
#endif #endif
/* Support for inter-process robust mutexes was added in 2.6.17. */ /* Support for inter-process robust mutexes was added in 2.6.17. */
#if __LINUX_KERNEL_VERSION >= 0x020611 #if __LINUX_KERNEL_VERSION >= 0x020611 \
&& ((!defined __sh__ && !defined __alpha__) \
|| (__LINUX_KERNEL_VERSION >= 0x020613 && defined __sh__) \
|| (__LINUX_KERNEL_VERSION >= 0x020617 && defined __alpha__))
# define __ASSUME_SET_ROBUST_LIST 1 # define __ASSUME_SET_ROBUST_LIST 1
#endif #endif
@ -459,8 +467,11 @@
# define __ASSUME_FUTEX_LOCK_PI 1 # define __ASSUME_FUTEX_LOCK_PI 1
#endif #endif
/* Support for utimensat syscall was added in 2.6.22. */ /* Support for utimensat syscall was added in 2.6.22, on alpha and s390
#if __LINUX_KERNEL_VERSION >= 0x020616 only after 2.6.22-rc1. */
#if __LINUX_KERNEL_VERSION >= 0x020616 \
&& ((!defined __sh__ && !defined __alpha__) \
|| __LINUX_KERNEL_VERSION >= 0x020617)
# define __ASSUME_UTIMENSAT 1 # define __ASSUME_UTIMENSAT 1
#endif #endif
@ -469,7 +480,10 @@
# define __ASSUME_PRIVATE_FUTEX 1 # define __ASSUME_PRIVATE_FUTEX 1
#endif #endif
/* Support for fallocate was added in 2.6.23. */ /* Support for fallocate was added in 2.6.23, on s390
#if __LINUX_KERNEL_VERSION >= 0x020617 only after 2.6.23-rc1. */
#if __LINUX_KERNEL_VERSION >= 0x020617 \
&& ((!defined __s390__ && !defined __alpha__) \
|| (__LINUX_KERNEL_VERSION >= 0x020618 && defined __s390__))
# define __ASSUME_FALLOCATE 1 # define __ASSUME_FALLOCATE 1
#endif #endif

View File

@ -1,4 +1,4 @@
/* Copyright (C) 2006 Free Software Foundation, Inc. /* Copyright (C) 2006, 2007 Free Software Foundation, Inc.
This file is part of the GNU C Library. This file is part of the GNU C Library.
Contributed by Ulrich Drepper <drepper@redhat.com>, 2006. Contributed by Ulrich Drepper <drepper@redhat.com>, 2006.
@ -26,9 +26,11 @@
#ifdef __NR_ppoll #ifdef __NR_ppoll
# ifndef __ASSUME_PPOLL
static int __generic_ppoll (struct pollfd *fds, nfds_t nfds, static int __generic_ppoll (struct pollfd *fds, nfds_t nfds,
const struct timespec *timeout, const struct timespec *timeout,
const sigset_t *sigmask); const sigset_t *sigmask);
# endif
int int

View File

@ -1,4 +1,4 @@
/* Copyright (C) 2006 Free Software Foundation, Inc. /* Copyright (C) 2006, 2007 Free Software Foundation, Inc.
This file is part of the GNU C Library. This file is part of the GNU C Library.
Contributed by Ulrich Drepper <drepper@redhat.com>, 2006. Contributed by Ulrich Drepper <drepper@redhat.com>, 2006.
@ -26,10 +26,12 @@
#ifdef __NR_pselect6 #ifdef __NR_pselect6
# ifndef __ASSUME_PSELECT
static int __generic_pselect (int nfds, fd_set *readfds, fd_set *writefds, static int __generic_pselect (int nfds, fd_set *readfds, fd_set *writefds,
fd_set *exceptfds, fd_set *exceptfds,
const struct timespec *timeout, const struct timespec *timeout,
const sigset_t *sigmask); const sigset_t *sigmask);
# endif
int int