Richard Henderson [Fri, 11 Jul 2014 17:56:42 +0000 (10:56 -0700)]
aarch64: Update libm-test-ulps
Florian Weimer [Thu, 10 Jul 2014 15:34:46 +0000 (17:34 +0200)]
nptl: Fix abort in case of set*id failure [BZ #17135]
If a call to the set*id functions fails in a multi-threaded program,
the abort introduced in commit
13f7fe35ae2b0ea55dc4b9628763aafdc8bdc30c
was triggered.
We address by checking that all calls to set*id on all threads give
the same result, and only abort if we see success followed by failure
(or vice versa).
Adhemerval Zanella [Thu, 10 Jul 2014 21:42:51 +0000 (16:42 -0500)]
PowerPC: Fix build due missing lll_robust_trylock
Commit 887865f remove the lll_robust_trylock definition on all
architectures, however for powerpc both __lll_trylock and
__lll_cond_trylock were based on lll_robust_trylock definition.
This patch restore it with a different name.
Roland McGrath [Thu, 10 Jul 2014 18:30:38 +0000 (11:30 -0700)]
ChangeLog fixup for last commit.
Roland McGrath [Thu, 10 Jul 2014 18:21:54 +0000 (11:21 -0700)]
Get rid of lll_robust_dead.
Roland McGrath [Thu, 10 Jul 2014 17:57:57 +0000 (10:57 -0700)]
Get rid of lll_robust_trylock.
Florian Weimer [Wed, 28 May 2014 12:05:03 +0000 (14:05 +0200)]
manual: Update the locale documentation
Florian Weimer [Mon, 12 May 2014 13:24:12 +0000 (15:24 +0200)]
_nl_find_locale: Improve handling of crafted locale names [BZ #17137]
Prevent directory traversal in locale-related environment variables
(CVE-2014-0475).
Florian Weimer [Wed, 28 May 2014 12:41:52 +0000 (14:41 +0200)]
setlocale: Use the heap for the copy of the locale argument
This avoids alloca calls with potentially large arguments.
Siddhesh Poyarekar [Thu, 10 Jul 2014 08:54:30 +0000 (14:24 +0530)]
Sync up error.c with gnulib
Summary of changes:
- Use of !_LIBC instead of HAVE_CONFIG_H
- Code changes in [!_LIBC] that don't affect us
- Minor formatting changes
- Use __builtin_expect in shared code
- Define some macros in [_LIBC] that are used in gnulib but never
defined in glibc
- Flip macro check for STRERROR_R_CHAR_P so that it does not throw a
warning
Siddhesh Poyarekar [Thu, 10 Jul 2014 08:51:27 +0000 (14:21 +0530)]
Fix -Wundef warning for HAVE_LOCALTIME_R
Define it to 0. There is a gnulib copy for this, but it is out of
sync with our copy.
Siddhesh Poyarekar [Thu, 10 Jul 2014 08:50:42 +0000 (14:20 +0530)]
Fix Wundef warning for HAVE_STRFTIME
Define it to 0
Siddhesh Poyarekar [Thu, 10 Jul 2014 08:49:21 +0000 (14:19 +0530)]
Fix -Wundef warning for HAVE_SYS_PARAM_H
Include sys/param.h unconditionally
Siddhesh Poyarekar [Thu, 10 Jul 2014 08:48:13 +0000 (14:18 +0530)]
Fix -Wundef warning for HAVE_OBSTACK
Remove the HAVE_OBSTACK macro check and include obstack check in
include path order since we don't have a copy of obstack.h in the
current directory.
Siddhesh Poyarekar [Thu, 10 Jul 2014 08:45:16 +0000 (14:15 +0530)]
Fix crash when system has no ipv6 address [BZ #17125]
Here's an updated patch to fix the crash in bug-ga2 when the system
has no configured ipv6 address. I have taken a different approach of
using libc_freeres_fn instead of the libc_freeres_ptr since the former
gives better control over what is freed; we need that since cache may
or may not be allocated using malloc.
Verified that bug-ga2 works correctly in both cases and does not have
memory leaks in either of them.
David S. Miller [Tue, 24 Jun 2014 20:31:04 +0000 (13:31 -0700)]
Get rid of sparc specific NPTL internaltypes.h header.
* sysdeps/sparc/nptl/internaltypes.h: Delete.
* sysdeps/sparc/nptl/sparc-nptl.h: New file.
* sysdeps/sparc/nptl/pthread_barrier_destroy.c: Include it.
* sysdeps/sparc/nptl/pthread_barrier_init.c: Likewise.
* sysdeps/sparc/nptl/pthread_barrier_wait.c: Likewise.
* sysdeps/sparc/nptl/sem_init.c: Likewise.
* sysdeps/sparc/nptl/sem_post.c: Likewise.
* sysdeps/sparc/nptl/sem_timedwait.c: Likewise.
* sysdeps/sparc/nptl/sem_wait.c: Likewise.
* sysdeps/sparc/sparc32/nptl/pthread_barrier_wait.c: Likewise.
* sysdeps/sparc/sparc32/nptl/sem_post.c: Likewise.
* sysdeps/sparc/sparc32/nptl/sem_timedwait.c: Likewise.
* sysdeps/sparc/sparc32/nptl/sem_wait.c: Likewise.
Siddhesh Poyarekar [Thu, 10 Jul 2014 05:02:29 +0000 (10:32 +0530)]
Add comment about SIZE initialization in xdr.c
David S. Miller [Thu, 10 Jul 2014 00:20:01 +0000 (17:20 -0700)]
Update sparc ULPS.
* sysdeps/sparc/fpu/libm-test-ulps: Update.
Andreas Schwab [Wed, 9 Jul 2014 09:06:00 +0000 (11:06 +0200)]
Fix missing newline in test output
Andreas Schwab [Wed, 9 Jul 2014 08:52:47 +0000 (10:52 +0200)]
Update i386 libm test ULPs
Will Newton [Mon, 7 Jul 2014 14:14:26 +0000 (15:14 +0100)]
Fix -Wundef warnings for SHARED
The definition of SHARED is tested with #ifdef pretty much everywhere
apart from these few places. The tlsdesc.c code seems to be copy and
pasted to a few architectures and there is one instance in the hppa
startup code.
ChangeLog:
2014-07-09 Will Newton <will.newton@linaro.org>
* sysdeps/aarch64/tlsdesc.c (_dl_unmap): Test SHARED with #ifdef.
* sysdeps/arm/tlsdesc.c (_dl_unmap): Likewise.
* sysdeps/i386/tlsdesc.c (_dl_unmap): Likewise.
* sysdeps/x86_64/tlsdesc.c (_dl_unmap): Likewise.
* sysdeps/hppa/start.S (_start): Likewise.
Siddhesh Poyarekar [Wed, 9 Jul 2014 05:06:50 +0000 (10:36 +0530)]
Fix -Wmaybe-uninitialized warning in xdr.c
While we're at fixing build warnings, here's one unnecessary warning
that can be fixed fairly easily. The SIZE variable is never actually
use uninitialized, but the compiler cannot make that out and thinks
(correctly) that there is a potential for accessing SIZE without
initializing it. Make this safe by initializing SIZE to 0.
Tested on x86_64.
Siddhesh Poyarekar [Wed, 9 Jul 2014 05:06:23 +0000 (10:36 +0530)]
Fix Wundef warning for __cplusplus
All current uses of the __cplusplus macro only check if it is defined
or not. Fix this #if to use $ifdef like the rest of the code.
Siddhesh Poyarekar [Tue, 8 Jul 2014 11:10:24 +0000 (16:40 +0530)]
Check value at resplen2 if it is not NULL
There was a typo in the previous patch due to which resplen2 was
checked for non-zero instead of the value at resplen2. Fix that and
improve the condition by checking resplen2 for non-NULL (instead of
answerp2) and also adding the check in a third place.
Siddhesh Poyarekar [Tue, 8 Jul 2014 10:49:55 +0000 (16:19 +0530)]
Fix Wundef warning for ELF_MACHINE_NO_REL on i386
Adhemerval Zanella [Tue, 8 Jul 2014 13:54:09 +0000 (08:54 -0500)]
PowerPC: Cleanup powerpc memmove
Now that MEMCPY_OK_FOR_FWD_MEMMOVE should be define on memcopy.h there
is no need to specialized powerpc memmove implementation. This patch
moves the define set to powerpc memcopy and cleanup its definition on
powerpc code.
Adhemerval Zanella [Tue, 8 Jul 2014 13:49:54 +0000 (08:49 -0500)]
PowerPC: Fix compiler warnings
This patch fixes some compiler due trailing data in #undef directives
and due missing prototypes.
Adhemerval Zanella [Tue, 8 Jul 2014 13:35:44 +0000 (08:35 -0500)]
PowerPC: Add ifunc tests for memmove
This patch add the missing ifunc tests definition for memmove ppc32
optimization patch (commit 07aedd7).
Siddhesh Poyarekar [Tue, 8 Jul 2014 09:32:58 +0000 (15:02 +0530)]
Fix Wundef warning with SHOJI_IS_RIGHT
The macro is not defined anywhere, so it looks like we're convinced
that Shoji is wrong :)
Adhemerval Zanella [Wed, 25 Jun 2014 16:54:31 +0000 (11:54 -0500)]
PowerPC: Align power7 memcpy using VSX to quadword
This patch changes power7 memcpy to use VSX instructions only when
memory is aligned to quardword. It is to avoid unaligned kernel traps
on non-cacheable memory (for instance, memory-mapped I/O).
Adhemerval Zanella [Tue, 24 Jun 2014 13:47:52 +0000 (08:47 -0500)]
PowerPC: optimized memmove for POWER7/PPC32
This patch adds a optimized memmove for power7 by using the optimized
power7 memcpy for forward copying.
Adhemerval Zanella [Fri, 20 Jun 2014 17:55:16 +0000 (12:55 -0500)]
PowerPC: optimized memmove for POWER7/PPC64
This patch adds an optimized memmove optimization for POWER7/powerpc64.
Basically the idea is to use the memcpy for POWER7 on non-overlapped
memory regions and a optimized backward memcpy for memory regions
that overlap (similar to the idea of string/memmove.c).
The backward memcpy algorithm used is similar the one use for memcpy for
POWER7, with adjustments done for alignment. The difference is memory
is always aligned to 16 bytes before using VSX/altivec instructions.
Adhemerval Zanella [Tue, 24 Jun 2014 11:42:31 +0000 (06:42 -0500)]
PowerPC: memmove default implementation cleanup
This patch removes the powerpc specific logic in memmove and instead
include default implementation with MEMCPY_OK_FOR_FWD_MEMMOVE defined.
This lead in a increase performance, since the constraints to use
memcpy in powerpc code are too restrictive and memcpy can be used for
any forward memmove.
Adhemerval Zanella [Tue, 24 Jun 2014 11:41:46 +0000 (06:41 -0500)]
PowerPC: Guard CALL_ELF check for ppc64 only in link.h
This patch fixes powerpc32 undef compiler warnings for _CALL_ELF,
since it is defined only for powerpc64.
Roland McGrath [Mon, 7 Jul 2014 16:29:34 +0000 (09:29 -0700)]
Remove old stub lowlevellock.h file. It is not even useful as documentation.
Roland McGrath [Mon, 7 Jul 2014 16:29:06 +0000 (09:29 -0700)]
NPTL is no longer an add-on!
Roland McGrath [Mon, 7 Jul 2014 16:28:38 +0000 (09:28 -0700)]
Get rid of nptl/sysdeps/ entirely!
Siddhesh Poyarekar [Fri, 4 Jul 2014 19:39:15 +0000 (01:09 +0530)]
Add comment for MEMCPY_OK_FOR_FWD_MEMMOVE
Will Newton [Thu, 26 Jun 2014 15:00:44 +0000 (16:00 +0100)]
string/memchr.c: Merge from gnulib
Merge most of the gnulib implementation of memchr. The changes that
remain are:
- copyright header
- bp-sym.h removed
- reg_char removed
- allow MEMCHR to be redefined
- non-conforming whitespace changes
The merged code fixes a number of -Wundef warnings and also introduces
an optimized algorithm. I haven't detected any performance difference
in the new code which I believe is down to the quite specific
circumstances required to hit it. However the new code is approximately
half the size of the old code on AArch64 (which uses generic memchr).
ChangeLog:
2014-07-04 Will Newton <will.newton@linaro.org>
* string/memchr.c: Merge from gnulib.
[_LIBC]: Remove conditionals.
(__ptr_t): Remove define.
(LONG_MAX_32_BITS): Likewise.
(LONG_MAX): Likewise.
(MEMCHR): Use ANSI prototype and optimize algorithm.
Will Newton [Thu, 3 Jul 2014 09:50:50 +0000 (10:50 +0100)]
ARM: Define ELF_MACHINE_NO_REL
Fix a -Wundef warning on ARM.
ChangeLog:
2014-07-04 Will Newton <will.newton@linaro.org>
* sysdeps/arm/dl-machine.h (ELF_MACHINE_NO_REL): Define.
Roland McGrath [Fri, 4 Jul 2014 05:03:14 +0000 (22:03 -0700)]
Fix ia64 build error in lll_futex_timed_wait_bitset
Roland McGrath [Fri, 4 Jul 2014 04:46:59 +0000 (21:46 -0700)]
Fix unwind.h configure check for bare environment.
Roland McGrath [Fri, 4 Jul 2014 04:15:56 +0000 (21:15 -0700)]
Add missing #include in sysdeps/alpha/fpu/s_nearbyint.c
Roland McGrath [Fri, 4 Jul 2014 03:35:42 +0000 (20:35 -0700)]
Robustify Linux kernel headers configure checks
Roland McGrath [Fri, 4 Jul 2014 02:17:00 +0000 (19:17 -0700)]
S390: Quash unused variable warning due to no-op THREAD_SET_POINTER_GUARD.
Siddhesh Poyarekar [Fri, 4 Jul 2014 01:52:51 +0000 (18:52 -0700)]
Restore subdir conditional for tst-timer dependency.
Richard Henderson [Thu, 3 Jul 2014 17:37:59 +0000 (10:37 -0700)]
alpha: Remove nearbyint and nearbyintf implementations
The original implementation was written for EV5, which does not
record inexact in the status register for /SU (but no /I) insns.
But EV6 does record the inexact status; the lack of /I simply
means that the exception is suppressed.
Adding feholdexcept becomes the bulk of the overhead, so we might
as well use the default implementation.
Richard Henderson [Thu, 3 Jul 2014 15:56:55 +0000 (08:56 -0700)]
alpha: Implement math_opt_barrier and math_force_eval
Richard Henderson [Thu, 3 Jul 2014 15:52:45 +0000 (08:52 -0700)]
alpha: Fix lround implementations
Use chopped rounding to add 0.5.
Richard Henderson [Thu, 3 Jul 2014 15:45:57 +0000 (08:45 -0700)]
alpha: Remove round and roundf implementations
Two bugs in these implementations: First is that the add of 0.5
was not done in chopped rounding mode (easily fixable). Second
is that the method generates incorrect inexact exceptions for
small integral values (not easily fixable).
Richard Henderson [Thu, 3 Jul 2014 15:37:55 +0000 (08:37 -0700)]
Changelog for last 8 patches
Richard Henderson [Tue, 1 Jul 2014 17:30:18 +0000 (10:30 -0700)]
Rely on HP_TIMING_AVAIL implies HP_SMALL_TIMING_AVAIL
Richard Henderson [Tue, 1 Jul 2014 17:20:14 +0000 (10:20 -0700)]
Always provide HP_SMALL_TIMING_AVAIL
Richard Henderson [Wed, 25 Jun 2014 21:02:39 +0000 (14:02 -0700)]
aarch64: Add hp-timing.h
Richard Henderson [Wed, 25 Jun 2014 20:58:59 +0000 (13:58 -0700)]
Unify hp-timing implementations
Provide an hp-timing-common.h for ports to use.
Richard Henderson [Wed, 25 Jun 2014 19:27:16 +0000 (12:27 -0700)]
Remove HP_TIMING_DIFF_INIT and dl_hp_timing_overhead
Without HP_TIMING_ACCUM, dl_hp_timing_overhead is write-only.
If we remove it, there's no point in HP_TIMING_DIFF_INIT either.
Richard Henderson [Wed, 25 Jun 2014 19:15:19 +0000 (12:15 -0700)]
Removing HP_TIMING_ACCUM as unused
Richard Henderson [Wed, 25 Jun 2014 18:40:18 +0000 (11:40 -0700)]
Removing HP_TIMING_ZERO as unused
Richard Henderson [Wed, 25 Jun 2014 18:36:52 +0000 (11:36 -0700)]
powerpc: Remove dummy hp-timing.h
It's the same as the generic dummy version.
Maciej W. Rozycki [Thu, 3 Jul 2014 07:07:55 +0000 (08:07 +0100)]
stdlib/tst-strtod-overflow: Bump timeout up yet
This test case is very, especially on targets using soft-float or QEMU
(where soft-float is used internally), and appears to be the only such
outlier. Therefore rather than requiring to have TIMEOUTFACTOR set
large enough globally, bump up the local scaling factor instead.
* stdlib/tst-strtod-overflow.c (TIMEOUT): Bump up to 30.
Siddhesh Poyarekar [Wed, 2 Jul 2014 20:06:10 +0000 (01:36 +0530)]
Sync up loadmsgcat.c with gettext
Siddhesh Poyarekar [Wed, 2 Jul 2014 20:02:17 +0000 (01:32 +0530)]
Fix Wundef warning for __STDC_VERSION__
c4c4124473c187b5c4642611390897666c3d3970 added the _Noreturn macro for
pre-C11 compilers, but it now throws a new Wundef warning during `make
check` for __STDC_VERSION__ which gcc does not define by default. The
following patch fixes this in line with other uses of __STDC_VERSION__
in the file.
Siddhesh Poyarekar [Wed, 2 Jul 2014 20:00:02 +0000 (01:30 +0530)]
Don't use __glibc_unlikely in shared code
Siddhesh Poyarekar [Wed, 2 Jul 2014 19:58:45 +0000 (01:28 +0530)]
Fix -Wundef warning on PAGE_COPY_THRESHOLD
The PAGE_COPY_THRESHOLD macro is meant to be overridden by
architecture-specific pagecopy.h, but it is currently done only by
mach; all other architectures use the default. Check to see if the
macro is defined in addition to whether it is set to a non-zero value.
Vidya Ranganathan [Thu, 12 Jun 2014 03:21:20 +0000 (22:21 -0500)]
PowerPC: strcat optimization for PPC64/POWER7
This patch adds an ifunc power7 strcat symbol that uses the logic on
sysdeps/powerpc/strcat.c but call power7 strlen/strcpy symbols instead
of default ones.
Roland McGrath [Wed, 2 Jul 2014 18:10:08 +0000 (11:10 -0700)]
Add missing #include for MIN use in dl-sysdep.c.
Siddhesh Poyarekar [Wed, 2 Jul 2014 11:27:48 +0000 (16:57 +0530)]
Fix typo and formatting in loadmsgcat.c
This reduces the differences with gettext version of loadmsgcat.c
Siddhesh Poyarekar [Wed, 2 Jul 2014 09:39:39 +0000 (15:09 +0530)]
Fix typo in macro name
It is _POSIX_SIGNALS and not _POSUX_SIGNALS
Will Newton [Mon, 23 Jun 2014 15:53:30 +0000 (16:53 +0100)]
malloc/obstack: Merge from gnulib
Merge the latest version of the obstack.c and obstack.h files
from gnulib. The majority of this change is coding style and
cosmetic comment changes but it also fixes a -Wundef warning
in the build as a side effect.
2014-07-02 Will Newton <will.newton@linaro.org>
* malloc/obstack.c: Merge from gnulib master.
[HAVE_CONFIG_H]: Remove conditional code.
[!_LIBC]: Include config.h.
[!ELIDE_CODE]: Don't include inttypes.h, include
stdint.h unconditionally.
(print_and_abort): Mark as _Noreturn.
(_obstack_allocated_p): Mark as __attribute_pure__.
(obstack_free): Rename to __obstack_free.
[!__attribute__]: Remove conditional code.
* malloc/obstack.h: Merge from gnulib master.
[__cplusplus]: Move conditional down.
[!__attribute_pure__]: Define __attribute_pure__ here
if it is not already defined.
(_obstack_memory_used): Mark as __attribute_pure__.
[!__obstack_free]: Define as obstack_free.
[__GNUC__]: Remove check for ancient NeXT gcc.
Paul Eggert [Fri, 28 Mar 2014 18:59:41 +0000 (11:59 -0700)]
misc/sys/cdefs.h: Add _Noreturn macro for pre-C11 compilers
2014-07-02 Will Newton <will.newton@linaro.org>
Paul Eggert <eggert@cs.ucla.edu>
* misc/sys/cdefs.h (_Noreturn): New macro, for pre-C11 compilers.
Siddhesh Poyarekar [Wed, 2 Jul 2014 07:55:55 +0000 (13:25 +0530)]
Add comment to gethnamaddr.c to warn that the file is unmaintained
Carlos O'Donell [Wed, 2 Jul 2014 07:11:53 +0000 (03:11 -0400)]
hppa: Remove GLIBC_2.3 from librt.abilist.
This commit removes the aio_cancel and aio_cancel64 symbols at
GLIBC_2.3 from the ABI baseline. The ABI baseline is now complete
for hppa and considered stable.
Carlos O'Donell [Wed, 2 Jul 2014 03:52:09 +0000 (23:52 -0400)]
hppa: Add ABI baselines.
The following ABI baselines were tested against several old releases
of debian and gentoo. Several problems were discovered and fixed as
part of developing the ABI baselines.
Firstly, libBrokenLocale on gentoo exports __ctype_get_mb_cur_max
as @@GLIBC_2.0, but it should be @@GLIBC_2.2 since that's the minimum
version defined in shlib-versions for hppa. I don't know when this
broke, but master properly parses hppa's shlib-versions which clearly
lists libBrokenLocale as defaulting to GLIBC_2.2. Therefore I'm
accepting GLBIC_2.2 as the correct version for this symbol and setting
the baseline to that, despite the fact that the present distribution
is wrong. I don't expect that any new applications should be using
libBrokenLocale, so it should match the oldest behaviour which is to
export a GLIBC_2.2 symbol. For example in debian's 2.7 has it at
version GLIBC_2.2.
Secondly, aio_cancel and aio_cancel64 previously had a compat symbol
at version @GLIBC_2.1 with a new symbol at @@GLIBC_2.3[1]. During the
Linuxthreads to NPTL transition the file aio_cancel.c was lost for hppa
and that resulted in just @@GLIBC_2.1 versions of these symbols being
exported. The @@GLIBC_2.1 version works correctly and uses the right
value of ECANCELLED. Therefore if I were to fix this today it might
break correctly working applications using aio_cancel*@GLIBC_2.1 by
causing those to use the old aio_cancel that used the older value
of ECANCELLED. Thus the best option is to accept that the ABI changed
and ignore older applications in favour of newer applications. The
best thing to do is cleanup the version files (included in the patch).
The rest of the ABI was as expected (ignoring __p_type_syms size
change in 2008).
Roland McGrath [Tue, 1 Jul 2014 22:01:24 +0000 (15:01 -0700)]
Add missing #include for MIN/MAX users.
Richard Henderson [Tue, 1 Jul 2014 15:27:49 +0000 (08:27 -0700)]
alpha: Fix isnan
The isunordered formulation raises SIGFPE for SNaN.
Richard Henderson [Tue, 1 Jul 2014 15:15:32 +0000 (08:15 -0700)]
alpha: Update libm-test-ulps
Stefan Liebler [Tue, 1 Jul 2014 14:04:58 +0000 (11:04 -0300)]
S/390: Regenerate ULPs
Siddhesh Poyarekar [Tue, 1 Jul 2014 08:44:09 +0000 (14:14 +0530)]
Remove MULTI_PTRS_ARE_ALIASES in dns-hosts.c
The code in gethnamaddr.c for gethostbyaddr used and set this macro to
allow multiple PTR records to be added as aliases. This was useful
for gethostbyaddr since it returns a hostent structure, which can
return aliases.
The gethnamaddr.c source however is unused in glibc since pretty much
forever. Instead, the DNS lookup bits for gethostbyaddr (as well as
getnameinfo) are implemented in dns-hosts.c and in that implementation
all but one (the first one) of the multiple PTR records are ignored.
Since gethnamaddr.c is essentially dead code, ignore that
implementation and replace the MULTI_PTRS_ARE_ALIASES bit with a
comment mentioning that bind adds PTR records as aliases while we
don't.
Joseph Myers [Tue, 1 Jul 2014 01:57:46 +0000 (11:57 +1000)]
MicroBlaze: Update kernel-features.h for syscalls added in 3.15
Now that the MicroBlaze 3.15 kernel has the pselect6, preadv and
pwritev syscalls, this patch updates kernel-features.h so they are
assumed to be present for 3.15 and later kernels.
2014-06-17 Joseph Myers <joseph@codesourcery.com>
* sysdeps/unix/sysv/linux/microblaze/kernel-features.h
[__LINUX_KERNEL_VERSION >= 0x030f00] (__ASSUME_PSELECT): Do not
undefine.
[__LINUX_KERNEL_VERSION >= 0x030f00] (__ASSUME_PREADV): Likewise.
[__LINUX_KERNEL_VERSION >= 0x030f00] (__ASSUME_PWRITEV): Likewise.
Signed-off-by: David Holsgrove <david.holsgrove@xilinx.com>
Roland McGrath [Wed, 25 Jun 2014 21:40:40 +0000 (14:40 -0700)]
MicroBlaze: Consolidate nptl/ subdirectories under linux/...
Signed-off-by: David Holsgrove <david.holsgrove@xilinx.com>
Roland McGrath [Wed, 25 Jun 2014 21:33:52 +0000 (14:33 -0700)]
MicroBlaze: Consolidate NPTL/non versions of vfork
Roland McGrath [Wed, 25 Jun 2014 18:18:27 +0000 (11:18 -0700)]
MicroBlaze: Move NPTL public headers to sysdeps/microblaze/nptl/.
Roland McGrath [Sat, 21 Jun 2014 00:34:56 +0000 (17:34 -0700)]
MicroBlaze: Define TLS_DEFINE_INIT_TP
Roland McGrath [Wed, 25 Jun 2014 18:17:28 +0000 (11:17 -0700)]
MicroBlaze: Convert fork.c to arch-fork.h
David Holsgrove [Mon, 30 Jun 2014 04:01:22 +0000 (14:01 +1000)]
MicroBlaze: Add missing sysdep-cancel.h implementation
And update socket.S, Makefile to use *_nocancel definitions.
Absence of sysdep-cancel.h was not apparent until Roland's
not-cancel.h unification.
2014-06-30 David Holsgrove <david.holsgrove@xilinx.com>
* sysdeps/unix/sysv/linux/microblaze/sysdep-cancel.h: New file
* sysdeps/unix/sysv/linux/microblaze/socket.S: Update SINGLE_THREAD_P
* sysdeps/unix/sysv/linux/microblaze/Makefile: Add to libpthread-routines
Signed-off-by: David Holsgrove <david.holsgrove@xilinx.com>
Adhemerval Zanella [Mon, 30 Jun 2014 21:38:43 +0000 (17:38 -0400)]
Update powerpc-fpu ULPs.
Joseph Myers [Mon, 30 Jun 2014 21:34:20 +0000 (21:34 +0000)]
Regenerate MIPS libm-test-ulps.
This patch regenerates libm-test-ulps for MIPS.
* sysdeps/mips/mips32/libm-test-ulps: Regenerated.
* sysdeps/mips/mips64/libm-test-ulps: Likewise.
Joseph Myers [Mon, 30 Jun 2014 21:26:49 +0000 (21:26 +0000)]
Regenerate powerpc-nofpu libm-test-ulps.
This patch regenerates libm-test-ulps for powerpc-nofpu.
* sysdeps/powerpc/nofpu/libm-test-ulps: Regenerated.
Joseph Myers [Mon, 30 Jun 2014 21:20:35 +0000 (21:20 +0000)]
Regenerate ARM libm-test-ulps.
This patch regenerates libm-test-ulps for ARM. As before it may be
useful for someone building for a configuration with VFMA enabled to
do a followup regeneration for any additional ulps in that
configuration.
Committed.
* sysdeps/arm/libm-test-ulps: Regenerated.
Maciej W. Rozycki [Mon, 30 Jun 2014 19:05:34 +0000 (20:05 +0100)]
test-skeleton: Kill any child process's offspring
This makes sure any subprocesses created by the program being tested get
killed as well if their parent times out. Otherwise if they are really
stuck, they may remain there running forever after the test case and
then the whole test suite has completed, until killed by hand.
* test-skeleton.c (signal_handler): Kill the whole process group
before killing the child individually.
(main): Report any failure on `setpgid'.
Roland McGrath [Mon, 30 Jun 2014 18:19:22 +0000 (11:19 -0700)]
ARM: Split Linuxism out of sysdeps/arm/nptl/tls.h
Joseph Myers [Mon, 30 Jun 2014 17:38:16 +0000 (17:38 +0000)]
Fix ldbl-128 expm1l spurious underflow (bug 16539).
This patch fixes spurious underflows from ldbl-128 expm1l, as reported
in <https://sourceware.org/ml/libc-alpha/2014-06/msg00835.html> and
exposed by the tests added for such a bug in the x86 / x86-64
version. The bug and fix are essentially the same, so no separate bug
is filed in Bugzilla.
Tested for mips64.
[BZ #16539]
* sysdeps/ieee754/ldbl-128/s_expm1l.c: Include <float.h>.
(__expm1l): Return argument unchanged when small but not
subnormal.
Joseph Myers [Mon, 30 Jun 2014 17:37:10 +0000 (17:37 +0000)]
Rename soft-fp op-[1248].h variables to avoid risk of shadowing.
Continuing the soft-fp variable renaming from
<https://sourceware.org/ml/libc-alpha/2014-06/msg00434.html> to avoid
shadowing if two macros happen to use the same variable name and that
variable is involved in an argument one of those macros passes to
another, this patch renames variables in op-[1248].h. (The two
patches are to different files and are independent of each other.)
Tested for powerpc32 (soft-float) and mips64 that this makes no change
to the disassembly of installed shared libraries.
* soft-fp/op-1.h (_FP_UNPACK_RAW_1): Rename local variables to
include macro name.
(_FP_UNPACK_RAW_1_P): Likewise.
(_FP_PACK_RAW_1): Likewise.
(_FP_PACK_RAW_1_P): Likewise.
(_FP_MUL_MEAT_1_wide): Likewise.
(_FP_MUL_MEAT_DW_1_hard): Likewise.
(_FP_MUL_MEAT_1_hard): Likewise.
(_FP_DIV_MEAT_1_imm): Likewise.
(_FP_DIV_MEAT_1_udiv_norm): Likewise.
(_FP_DIV_MEAT_1_udiv): Likewise.
* soft-fp/op-2.h (__FP_FRAC_DEC_2): Likewise.
(_FP_UNPACK_RAW_2): Likewise.
(_FP_UNPACK_RAW_2_P): Likewise.
(_FP_PACK_RAW_2): Likewise.
(_FP_PACK_RAW_2_P): Likewise.
(_FP_MUL_MEAT_DW_2_wide): Likewise.
(_FP_MUL_MEAT_2_wide): Likewise.
(_FP_MUL_MEAT_DW_2_wide_3mul): Likewise.
(_FP_MUL_MEAT_2_wide_3mul): Likewise.
(_FP_MUL_MEAT_DW_2_gmp): Likewise.
(_FP_MUL_MEAT_2_gmp): Likewise.
(_FP_DIV_MEAT_2_udiv): Likewise.
* soft-fp/op-4.h (_FP_FRAC_SLL_4): Likewise.
(_FP_FRAC_SRL_4): Likewise.
(_FP_FRAC_SRST_4): Likewise.
(_FP_FRAC_SRS_4): Likewise.
(_FP_UNPACK_RAW_4): Likewise.
(_FP_UNPACK_RAW_4_P): Likewise.
(_FP_PACK_RAW_4): Likewise.
(_FP_PACK_RAW_4_P): Likewise.
(_FP_MUL_MEAT_DW_4_wide): Likewise.
(_FP_MUL_MEAT_4_wide): Likewise.
(_FP_MUL_MEAT_4_gmp): Likewise.
(umul_ppppmnnn): Likewise.
(_FP_DIV_MEAT_4_udiv): Likewise.
(__FP_FRAC_ADD_4): Likewise.
(__FP_FRAC_SUB_3): Likewise.
(__FP_FRAC_SUB_4): Likewise.
(__FP_FRAC_DEC_3): Likewise.
(__FP_FRAC_DEC_4): Likewise.
(__FP_FRAC_ADDI_4): Likewise.
* soft-fp/op-8.h (_FP_FRAC_SLL_8): Likewise.
(_FP_FRAC_SRL_8): Likewise.
(_FP_FRAC_SRS_8): Likewise.
Joseph Myers [Mon, 30 Jun 2014 17:36:18 +0000 (17:36 +0000)]
Rename soft-fp extended.h, op-common.h variables to avoid risk of shadowing.
In <https://sourceware.org/ml/libc-alpha/2013-06/msg00851.html>, I
fixed a bug caused by multiple soft-fp macros using the same variable
names, resulting in shadowing when one macro called another that used
the same variable name, with an argument involving the variable in the
outer macro. The fix was to rename the local variables so their names
included the containing macro name, to ensure uniqueness.
I noted then that this would make sense more systematically for all
variables in any soft-fp macro. Since then, I've used such variable
names in new soft-fp macros. This patch now converts existing macros
in extended.h and op-common.h to use this convention. (op-[1248].h
are intended to be converted separately.)
(Name conflicts could arise for label names as well, but because those
are function-scope in C any such conflict will give an immediate
compile error rather than a subtle bug, so there's no need for
preemptive renaming in that case.)
Tested for powerpc32 (soft-float) and mips64 that this makes no change
to the disassembly of installed shared libraries.
* soft-fp/extended.h (FP_UNPACK_RAW_E): Rename local variables to
include macro name.
(FP_UNPACK_RAW_EP): Likewise.
(FP_PACK_RAW_E): Likewise.
(FP_PACK_RAW_EP): Likewise.
* soft-fp/op-common.h (_FP_UNPACK_CANONICAL): Likewise.
(_FP_ISSIGNAN): Likewise.
(_FP_ADD_INTERNAL): Likewise.
(_FP_FMA): Likewise.
(_FP_CMP): Likewise.
(_FP_SQRT): Likewise.
(_FP_TO_INT): Likewise.
(_FP_FROM_INT): Likewise.
(FP_EXTEND): Likewise.
(_FP_DIV_MEAT_N_loop): Likewise.
Maciej W. Rozycki [Mon, 30 Jun 2014 09:38:49 +0000 (10:38 +0100)]
sysdeps/unix/sysv/linux/bits/socket.h: Correct formatting
* sysdeps/unix/sysv/linux/bits/socket.h: Adjust macro formatting
throughout.
Joseph Myers [Sun, 29 Jun 2014 11:49:08 +0000 (11:49 +0000)]
Fix ldbl-128 powl sign of result in overflow / underflow cases (bug 17097).
This patch fixes bug 17097, ldbl-128 powl producing overflowing /
underflowing results with positive sign when the result should have
been negative. This was shown up by the tests in non-default rounding
modes added by my patch for bug 16315, but isn't actually limited to
non-default rounding modes: rather, when rounding to nearest the
wrappers produced a result with the correct sign and so always hid the
bug unless -lieee was used to disable the wrappers. The problem is
that in the cases where Y is large enough that the result overflows or
underflows for X not very close to 1, but not large enough to overflow
or underflow for all X != +/- 1 (in the latter case Y is always an
even integer), a positive overflowing / underflowing result is always
returned, rather than one with the correct sign. This patch moves the
relevant part of computation of the sign earlier and returns a result
of the correct sign.
Tested for mips64.
[BZ #17097]
* sysdeps/ieee754/ldbl-128/e_powl.c (__ieee754_powl): Return
result with correct sign in case of exponents that produce
overflow except for X very close to 1.
Paul Eggert [Sat, 28 Jun 2014 00:45:54 +0000 (06:15 +0530)]
Sync up mktime with gnulib
From the gnulib commit log:
commit
e2646b0c6b5acda25e9ffeb4c12a5513a1e3b5ac
Author: Paul Eggert <eggert@cs.ucla.edu>
Date: Fri Jun 27 11:35:44 2014 -0700
mktime: merge #if/#ifdef usage from glibc
* lib/mktime.c: Use "#if defined DEBUG && DEBUG", not "#if DEBUG",
as that works with both Glibc's and Gnulib's style.
See thread starting at Siddhesh Poyarekar's bug report at:
http://lists.gnu.org/archive/html/bug-gnulib/2014-06/msg00102.html
Siddhesh Poyarekar [Sat, 28 Jun 2014 00:35:24 +0000 (06:05 +0530)]
Fix Wundef warning for MEMCPY_OK_FOR_FWD_MEMMOVE
Define MEMCPY_OK_FOR_FWD_MEMMOVE in memcopy.h and let arch-specific
implementations of that file override the value if necessary. This
override is only useful for tile and moving this macro to memcopy.h
allows us to remove the tile-specific memmove.c.
Joseph Myers [Fri, 27 Jun 2014 20:24:23 +0000 (20:24 +0000)]
Remove shlib-versions ABI names support.
shlib-versions files can contain ABI lines that map triplets to a
canonical ABI name. This name was once used for various purposes
where test baseline files for different ABIs went in a single
directory; now these purposes use sysdeps files, generation of headers
which have per-ABI variants uses abi-variants and related Makefile
variables and the shlib-versions ABI names are unused. This patch
duly removes those lines and associated build system support for them.
Tested for x86_64 (both a full testsuite run and confirming the
installed shared libraries are unchanged by the patch).
* Makeconfig ($(common-objpfx)soversions.mk): Do not generate
abi-name definition.
* scripts/soversions.awk: Do not handle or generate ABI lines.
* shlib-versions: Remove ABI entries.
* sysdeps/powerpc/nofpu/shlib-versions: Remove file.
* sysdeps/x86_64/x32/shlib-versions: Remove ABI entry.
Roland McGrath [Fri, 27 Jun 2014 18:41:04 +0000 (11:41 -0700)]
MIPS: Consolidate nptl/ subdirectories under linux/...