| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
| |
__int128 was added in GCC 4.6 and __int128_t was added before x86-64
was supported. This patch replaces __int128 with __int128_t so that
the installed bits/link.h can be used with older GCC.
* sysdeps/x86/bits/link.h (La_x86_64_regs): Replace __int128
with __int128_t.
(La_x86_64_retval): Likewise.
|
| |
|
| |
|
|
|
|
|
|
| |
* sysdeps/unix/sysv/linux/sparc/bits/sigaction.h
(struct sigaction): New struct member __glibc_reserved0, change
type of sa_flags to int.
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Add setjmp, longjmp and longjmp_target SystemTap probes.
ChangeLog:
2014-04-22 Will Newton <will.newton@linaro.org>
Venkataramanan Kumar <venkataramanan.kumar@linaro.org>
* sysdeps/aarch64/__longjmp.S: Include stap-probe.h.
(__longjmp): Add longjmp and longjmp_target SystemTap
probes.
* sysdeps/aarch64/setjmp.S: Include stap-probe.h.
(__sigsetjmp): Add setjmp SystemTap probe.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
In the glibc manual we have a "Roadmap to the manual" section at
the end of the "Introduction" chapter.
The introductory text says "Here is an overview of the contents
of the remaining chapters of this manual.", but then proceeds to
list chapters out of order and some chapter are never referenced.
This commit reorders the overview to correctly match the manual
order.
See:
https://sourceware.org/ml/libc-alpha/2014-02/msg00823.html
|
|
|
|
|
|
|
|
| |
This patch removes the arch specific powerpc implementation and instead
uses the linux default one. Although the current powerpc implementation
already constains the required memory barriers for correct
initialization, the default implementation shows a better performance on
newer chips.
|
|
|
|
|
| |
This patch add the missing libc_<function>l_ctx macros for long
double. Similar for float, they point to default double versions.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This patch checks and sets bit_AVX2_Usable in __cpu_features.feature.
* sysdeps/x86_64/multiarch/ifunc-defines.sym (COMMON_CPUID_INDEX_7):
New.
* sysdeps/x86_64/multiarch/init-arch.c (__init_cpu_features):
Check and set bit_AVX2_Usable.
* sysdeps/x86_64/multiarch/init-arch.h (bit_AVX2_Usable): New
macro.
(bit_AVX2): Likewise.
(index_AVX2_Usable): Likewise.
(CPUID_AVX2): Likewise.
(HAS_AVX2): Likewise.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Calling setcontext from a signal handler can be done safely so
it is sufficient to note that it is not recommended.
Also mention in setcontext documentation that the behaviour of
setcontext when restoring a context created by a call to a signal
handler is unspecified.
2014-04-17 Will Newton <will.newton@linaro.org>
* manual/setjmp.texi (System V contexts): Add note that
calling setcontext on a context created by a call to a
signal handler is undefined. Update text to note that
setcontext from a signal handler is possible but not
recommended.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
On aarch64 calling swapcontext clobbers the state of the signal
stack (BZ #16629). Check that the address and size of the signal
stack before and after the call to swapcontext remains the same.
ChangeLog:
2014-04-17 Will Newton <will.newton@linaro.org>
[BZ #16629]
* stdlib/tst-setcontext.c: Include signal.h.
(main): Check that the signal stack before and
after swapcontext is the same.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The current implementation of setcontext uses rt_sigreturn to restore
the contents of registers. This contrasts with the way most other
architectures implement setcontext:
powerpc64, mips, tile:
Call rt_sigreturn if context was created by a call to a signal handler,
otherwise restore in user code.
powerpc32:
Call swapcontext system call and don't call sigreturn or rt_sigreturn.
x86_64, sparc, hppa, sh, ia64, m68k, s390, arm:
Only support restoring "synchronous" contexts, that is contexts
created by getcontext, and restoring in user code and don't call
sigreturn or rt_sigreturn.
alpha:
Call sigreturn (but not rt_sigreturn) in all cases to do the restore.
The text of the setcontext manpage suggests that the requirement to be
able to restore a signal handler created context has been dropped from
SUSv2:
If the context was obtained by a call to a signal handler, then old
standard text says that "program execution continues with the program
instruction following the instruction interrupted by the signal".
However, this sentence was removed in SUSv2, and the present verdict
is "the result is unspecified".
Implementing setcontext by calling rt_sigreturn unconditionally causes
problems when used with sigaltstack as in BZ #16629. On this basis it
seems that aarch64 is broken and that new ports should only support
restoring contexts created with getcontext and do not need to call
rt_sigreturn at all.
This patch re-implements the aarch64 setcontext function to restore
the context in user code in a similar manner to x86_64 and other ports.
ChangeLog:
2014-04-17 Will Newton <will.newton@linaro.org>
[BZ #16629]
* sysdeps/unix/sysv/linux/aarch64/setcontext.S (__setcontext):
Re-implement to restore registers in user code and avoid
rt_sigreturn system call.
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This patch saves and restores bound registers in x86-64 PLT for
ld.so profile and LD_AUDIT:
* sysdeps/x86_64/bits/link.h (La_x86_64_regs): Add lr_bnd.
(La_x86_64_retval): Add lrv_bnd0 and lrv_bnd1.
* sysdeps/x86_64/dl-trampoline.S (_dl_runtime_profile): Save
Intel MPX bound registers before _dl_profile_fixup.
* sysdeps/x86_64/dl-trampoline.h: Restore Intel MPX bound
registers after _dl_profile_fixup. Save and restore bound
registers bnd0/bnd1 when calling _dl_call_pltexit.
* sysdeps/x86_64/link-defines.sym (BND_SIZE): New.
(LR_BND_OFFSET): Likewise.
(LRV_BND0_OFFSET): Likewise.
(LRV_BND1_OFFSET): Likewise.
|
|
|
|
|
|
| |
* sysdeps/mach/hurd/i386/tls.h (tcbhead_t): Add multiple_threads,
sysinfo, stack_guard, pointer_guard, gscope_flag, private_futex,
__private_tm, __private_ss fields.
|
| |
|
|
|
|
| |
* sysdeps/mach/munmap.c (__munmap): Return EINVAL if `addr' is 0.
|
| |
|
| |
|
|
|
|
| |
mode.
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
Besides fixing the bugzilla, this also fixes corner-cases where the high
and low double differ greatly in magnitude, and handles a denormal
input without resorting to a fp rescale.
[BZ #16740]
[BZ #16619]
* sysdeps/ieee754/ldbl-128ibm/s_frexpl.c (__frexpl): Rewrite.
* math/libm-test.inc (frexp_test_data): Add tests.
|
|
|
|
|
|
|
|
|
|
| |
Using -lm and -lpthread results in the shared objects in the system
being used to link against. This happened to work for libm because
there haven't been any changes to the libm ABI recently that could
break the existing benchmarks. This doesn't always work for the
pthread benchmarks. The correct way to build against libraries in the
build directory is to have the binaries explicitly depend on them so
that $(+link) can pick them up.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
We initialize _r_debug for static binaries to allows debug
agents to treat static binaries a little more like dyanmic
ones. This simplifies the work a debug agent has to do to
access TLS in a static binary via libthread_db.
Tested on x86_64.
See:
https://sourceware.org/ml/libc-alpha/2014-04/msg00183.html
[BZ #16831]
* csu/libc-start.c (LIBC_START_MAIN) [!SHARED]: Call
_dl_debug_initialize.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The SELinux team has indicated to me that glibc's SELinux checks
in nscd are not being carried out as they would expect the API
to be used today. They would like to move away from static header
defines for class and permissions and instead use dynamic checks
at runtime that provide an answer which is dependent on the runtime
status of SELinux i.e. more dynamic.
The following patch is a minimal change that moves us forward in
this direction.
It does the following:
* Stop checking for SELinux headers that define NSCD__SHMEMHOST.
Check only for the presence or absence of the library.
* Don't encode the specific SELinux permission constants into a
table at build time, and instead use the symbolic name for the
permission as expected.
* Lookup the "What do we do if we don't know this permission?"
policy and use that if we find SELinux's policy is older than
the glibc policy e.g. we make a request for a permission that
SELinux doesn't know about.
* Lastly, translate the class and permission and then make
the permission check. This is done every time we lookup
a permission, and this is the expected way to use the API.
SELinux will optimize this for us, and we expect the network
latencies to hide these extra library calls.
Tested on x86, x86-64, and via Fedora Rawhide since November 2013.
See:
https://sourceware.org/ml/libc-alpha/2014-04/msg00179.html
|
|
|
|
| |
* sysdeps/sparc/fpu/libm-test-ulps: Update.
|
| |
|
| |
|
|
|
|
| |
This fixes a testsuite failure for tile (and possibly microblaze).
|
|
|
|
|
| |
* elf/Makefile (tests): make tst-dlopen-aout conditional on
enable-hardcoded-path-in-tests
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Add a small library to print JSON values and use it to improve the
readability of the benchmark output and the readability of the
benchmark code.
ChangeLog:
2014-04-11 Will Newton <will.newton@linaro.org>
* benchtests/Makefile (extra-objs): Add json-lib.o.
(bench-func): Tidy up JSON output.
* benchtests/bench-skeleton.c: Include json-lib.h.
(main): Use JSON library functions to do output of
benchmark results.
* benchtests/bench-timing-type.c (main): Output the
timing type simply, leaving formatting to the user.
* benchtests/json-lib.c: New file.
* benchtests/json-lib.h: Likewise.
|
|
|
|
|
|
|
| |
[BZ #15215] This unifies various pthread_once architecture-specific
implementations which were using the same algorithm with slightly different
implementations. It also adds missing memory barriers that are required for
correctness.
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
MALLOC_DEBUG is set optionally on the command line. Default the value
to zero if it is not set on the command line, and test its value
with #if rather than #ifdef. Verified the code is identical before
and after this change apart from line numbers.
ChangeLog:
2014-04-11 Will Newton <will.newton@linaro.org>
* malloc/malloc.c [!MALLOC_DEBUG]: #define MALLOC_DEBUG
to zero if it is not defined elsewhere. (mtrim): Test
the value of MALLOC_DEBUG with #if rather than #ifdef.
|
|
|
|
|
|
|
|
|
| |
We have a single thread that runs a no-op initialization once and then
repeatedly runs checks of the initialization (i.e., an acquire load and
conditional jump) in a tight loop. This gives us, on average, the
best-case latency of pthread_once (the initialization is the
exactly-once slow path, and we're not looking at initialization-related
synchronization overheads in this case).
|