Bug ID: 22685
Summary: PowerPC: Static AT_SECURE binaries segfault with
lock-elision and tunables
Assignee: unassigned at sourceware dot org
Reporter: aurelien at aurel32 dot net
CC: drepper.fsp at gmail dot com
Target Milestone: ---
Since the introduction of tunables in commit 67e58f39 (which is in 2.25) and
when the GNU libc is configured with --enable-tunables
--enable-lock-elision=yes the stdlib/tst-secure-getent test fails with
segmentation fault. This is also true for elf/tst-env-setuid and
elf/tst-env-setuid-tunables that has been added a few commits later.
Note that since glibc 2.26 tunables are enabled by default and since commit
07ed18d2 (which will be in 2.27) lock elision support is always compiled.
The issue comes from the use of __access_noerrno in maybe_enable_malloc_check
in elf/dl-tunables.c to check for /etc/suid-debug. On PowerPC, transactions are
aborted just before syscalls, by using this code from sysdeps/powerpc/sysdep.h:
The problem is that on static binaries __thread_register is not yet initialized
when maybe_enable_malloc_check is executed, causing a segmentation fault. Just
removing the __access_noerrno test workarounds the issue.
You are receiving this mail because:
You are on the CC list for the bug.