[Bug libc/21956] New: Unbounded stack allocation in pthread_rwlock_rdlock
aurelien at aurel32 dot net
sourceware-bugzilla@sourceware.org
Tue Aug 15 23:36:00 GMT 2017
https://sourceware.org/bugzilla/show_bug.cgi?id=21956
Bug ID: 21956
Summary: Unbounded stack allocation in pthread_rwlock_rdlock
Product: glibc
Version: unspecified
Status: NEW
Severity: normal
Priority: P2
Component: libc
Assignee: unassigned at sourceware dot org
Reporter: aurelien at aurel32 dot net
CC: drepper.fsp at gmail dot com
Target Milestone: ---
Host: mipsel-unknown-linux-gnu
Target: mipsel-unknown-linux-gnu
Build: mipsel-unknown-linux-gnu
Since commit cc25c8b4c1 ("New pthread rwlock that is more scalable.") the futex
syscall is used in a loop. It takes 6th arguments. On mips o32, the first four
are passed in registers while the last two are passed on the stack. The current
code in sysdeps/unix/sysv/linux/mips/mips32/sysdep.h uses an alloca(4) call to
force the use of a frame pointer. This allocates an unbounded amounts of stack.
This is the reason why nptl/tst-rwlock15 now fails with a segmentation fault.
--
You are receiving this mail because:
You are on the CC list for the bug.
More information about the Glibc-bugs
mailing list