Andreas Schwab [Tue, 12 Nov 2013 10:16:14 +0000 (11:16 +0100)]
Install uz_UZ.UTF-8 locale (BZ #16095)
Joseph Myers [Wed, 4 Jun 2014 23:37:25 +0000 (23:37 +0000)]
Include LOCPATH in default test environment.
Tests run using the default $(make-test-out) automatically get
GCONV_PATH and LC_ALL set, whether or not those environment variables
are actually needed for the individual test. However, they do not get
LOCPATH set, meaning that a large number of tests have -ENV settings
just to set LOCPATH.
This patch moves LOCPATH into the default environment used for all
tests, on the principle that like GCONV_PATH any settings needed to
use files associated with the newly built library, rather than any old
installed files, are appropriate to use by default.
A further motivation is that various tests using .sh files also set
some combination of LC_ALL, GCONV_PATH and LOCPATH. Preferably .sh
files should also use the default environment with any additions
required for the individual test. Now, it was suggested in
<https://sourceware.org/ml/libc-alpha/2014-05/msg00715.html> that
various Makefile variables used in testing should be derived by
composing the -before-env and -after-env variables used when explicit
environment settings are required. With such a change, it's also
natural for those variables to include the default settings (via some
intermediate makefile variable also used in make-test-out).
Because some .sh files only set variables that correspond to the
default settings, or a subset thereof, and this applies to more of the
.sh files once LOCPATH is in the default settings, doing so reduces
the size of a revised version of
<https://sourceware.org/ml/libc-alpha/2014-05/msg00596.html>: scripts
only needing the (expanded) default settings will not need to receive
the separate -before-env and -after-env variables, only the single
variable they do at present. So moving LOCPATH into the default
settings can reduce churn caused by subsequent patches.
Tested x86_64 and x86.
* Rules (make-test-out): Include
LOCPATH=$(common-objpfx)localedata in default environment.
* debug/Makefile (tst-chk1-ENV): Remove variable.
(tst-chk2-ENV): Likewise.
(tst-chk3-ENV): Likewise.
(tst-chk4-ENV): Likewise.
(tst-chk5-ENV): Likewise.
(tst-chk6-ENV): Likewise.
(tst-lfschk1-ENV): Likewise.
(tst-lfschk2-ENV): Likewise.
(tst-lfschk3-ENV): Likewise.
(tst-lfschk4-ENV): Likewise.
(tst-lfschk5-ENV): Likewise.
(tst-lfschk6-ENV): Likewise.
* iconvdata/Makefile (bug-iconv6-ENV): Likewise.
(tst-iconv7-ENV): Likewise.
* intl/Makefile (LOCPATH-ENV): Likewise.
(tst-codeset-ENV): Likewise.
(tst-gettext3-ENV): Likewise.
(tst-gettext5-ENV): Likewise.
* libio/Makefile (tst-widetext-ENV): Don't set LOCPATH.
(tst-fopenloc-ENV): Likewise.
(tst-fgetws-ENV): Remove variable.
(tst-ungetwc1-ENV): Likewise.
(tst-ungetwc2-ENV): Likewise.
(bug-ungetwc2-ENV): Likewise.
(tst-swscanf-ENV): Likewise.
(bug-ftell-ENV): Likewise.
(tst-fgetwc-ENV): Likewise.
(tst-fseek-ENV): Likewise.
(tst-ftell-partial-wide-ENV): Likewise.
(tst-ftell-active-handler-ENV): Likewise.
(tst-ftell-append-ENV): Likewise.
* posix/Makefile (tst-fnmatch-ENV): Likewise.
(tst-regexloc-ENV): Likewise.
(bug-regex1-ENV): Likewise.
(tst-regex-ENV): Likewise.
(tst-regex2-ENV): Likewise.
(bug-regex5-ENV): Likewise.
(bug-regex6-ENV): Likewise.
(bug-regex17-ENV): Likewise.
(bug-regex18-ENV): Likewise.
(bug-regex19-ENV): Likewise.
(bug-regex20-ENV): Likewise.
(bug-regex22-ENV): Likewise.
(bug-regex23-ENV): Likewise.
(bug-regex25-ENV): Likewise.
(bug-regex26-ENV): Likewise.
(bug-regex30-ENV): Likewise.
(bug-regex32-ENV): Likewise.
(bug-regex33-ENV): Likewise.
(bug-regex34-ENV): Likewise.
(bug-regex35-ENV): Likewise.
(tst-rxspencer-ENV): Likewise.
(tst-rxspencer-no-utf8-ENV): Likewise.
* stdio-common/Makefile (tst-sprintf-ENV): Likewise.
(tst-sscanf-ENV): Likewise.
(tst-swprintf-ENV): Likewise.
(tst-swscanf-ENV): Likewise.
(test-vfprintf-ENV): Likewise.
(scanf13-ENV): Likewise.
(bug14-ENV): Likewise.
(tst-grouping-ENV): Likewise.
* stdlib/Makefile (tst-strtod-ENV): Likewise.
(tst-strtod3-ENV): Likewise.
(tst-strtod4-ENV): Likewise.
(tst-strtod5-ENV): Likewise.
(testmb2-ENV): Likewise./
* string/Makefile (tst-strxfrm-ENV): Likewise.
(tst-strxfrm2-ENV): Likewise.
(bug-strcoll1-ENV): Likewise.
(test-strcasecmp-ENV): Likewise.
(test-strncasecmp-ENV): Likewise.
* time/Makefile (tst-strptime-ENV): Likewise.
(tst-ftime_l-ENV): Likewise.
* wcsmbs/Makefile (tst-btowc-ENV): Likewise.
(tst-mbrtowc-ENV): Likewise.
(tst-wcrtomb-ENV): Likewise.
(tst-mbrtowc2-ENV): Likewise.
(tst-c16c32-1-ENV): Likewise.
(tst-mbsnrtowcs-ENV): Likewise.
localedata/ChangeLog:
* Makefile (TEST_MBWC_ENV): Remove variable.
(tst_iswalnum-ENV): Likewise.
(tst_iswalpha-ENV): Likewise.
(tst_iswcntrl-ENV): Likewise.
(tst_iswctype-ENV): Likewise.
(tst_iswdigit-ENV): Likewise.
(tst_iswgraph-ENV): Likewise.
(tst_iswlower-ENV): Likewise.
(tst_iswprint-ENV): Likewise.
(tst_iswpunct-ENV): Likewise.
(tst_iswspace-ENV): Likewise.
(tst_iswupper-ENV): Likewise.
(tst_iswxdigit-ENV): Likewise.
(tst_mblen-ENV): Likewise.
(tst_mbrlen-ENV): Likewise.
(tst_mbrtowc-ENV): Likewise.
(tst_mbsrtowcs-ENV): Likewise.
(tst_mbstowcs-ENV): Likewise.
(tst_mbtowc-ENV): Likewise.
(tst_strcoll-ENV): Likewise.
(tst_strfmon-ENV): Likewise.
(tst_strxfrm-ENV): Likewise.
(tst_swscanf-ENV): Likewise.
(tst_towctrans-ENV): Likewise.
(tst_towlower-ENV): Likewise.
(tst_towupper-ENV): Likewise.
(tst_wcrtomb-ENV): Likewise.
(tst_wcscat-ENV): Likewise.
(tst_wcschr-ENV): Likewise.
(tst_wcscmp-ENV): Likewise.
(tst_wcscoll-ENV): Likewise.
(tst_wcscpy-ENV): Likewise.
(tst_wcscspn-ENV): Likewise.
(tst_wcslen-ENV): Likewise.
(tst_wcsncat-ENV): Likewise.
(tst_wcsncmp-ENV): Likewise.
(tst_wcsncpy-ENV): Likewise.
(tst_wcspbrk-ENV): Likewise.
(tst_wcsrtombs-ENV): Likewise.
(tst_wcsspn-ENV): Likewise.
(tst_wcsstr-ENV): Likewise.
(tst_wcstod-ENV): Likewise.
(tst_wcstok-ENV): Likewise.
(tst_wcstombs-ENV): Likewise.
(tst_wcswidth-ENV): Likewise.
(tst_wcsxfrm-ENV): Likewise.
(tst_wctob-ENV): Likewise.
(tst_wctomb-ENV): Likewise.
(tst_wctrans-ENV): Likewise.
(tst_wctype-ENV): Likewise.
(tst_wcwidth-ENV): Likewise.
(tst-digits-ENV): Likewise.
(tst-mbswcs6-ENV): Likewise.
(tst-xlocale1-ENV): Likewise.
(tst-xlocale2-ENV): Likewise.
(tst-strfmon1-ENV): Likewise.
(tst-strptime-ENV): Likewise.
(tst-setlocale-ENV): Don't set LOCPATH.
(bug-iconv-trans-ENV): Remove variable.
(tst-sscanf-ENV): Likewise.
(tst-leaks-ENV): Don't set LOCPATH.
(bug-setlocale1-ENV): Remove variable.
(bug-setlocale1-static-ENV): Likewise.
(tst-setlocale2-ENV): Likewise.
Ondřej Bílka [Wed, 4 Jun 2014 22:40:01 +0000 (00:40 +0200)]
Fix typo in manual.
David S. Miller [Tue, 3 Jun 2014 23:14:06 +0000 (16:14 -0700)]
Fixup ChangeLog and add missing NEWS entry for previous commits.
Guo Yixuan [Fri, 30 May 2014 04:53:16 +0000 (21:53 -0700)]
New test for pthread_spin_lock (bug 16882)
* nptl/tst-spin4.c: New test.
* nptl/Makefile (tests): Add tst-spin4.
Guo Yixuan [Fri, 30 May 2014 04:43:15 +0000 (21:43 -0700)]
Fixed pthread_spin_lock on sparc32/64 (bug 16882)
[BZ #16882]
* nptl/sysdeps/sparc/sparc32/pthread_spin_lock.S
(pthread_spin_lock): Branch out of spin loop to proper location.
* nptl/sysdeps/sparc/sparc64/pthread_spin_lock.S
(pthread_spin_lock): Likewise.
Andreas Schwab [Mon, 26 May 2014 16:01:31 +0000 (18:01 +0200)]
Fix invalid file descriptor reuse while sending DNS query (BZ #15946)
Richard Henderson [Tue, 3 Jun 2014 15:27:32 +0000 (11:27 -0400)]
aarch64: Remove nptl/vfork.S
Stefan Liebler [Tue, 3 Jun 2014 15:27:13 +0000 (17:27 +0200)]
S/390: Regenerate ULPs.
Richard Henderson [Fri, 23 May 2014 20:23:32 +0000 (16:23 -0400)]
aarch64: Consolidate NPTL/non versions of vfork
At the same time, incorporate the 0 -> 0x80000000 mapping
of the pid expected by raise.c.
Richard Henderson [Fri, 23 May 2014 19:44:23 +0000 (15:44 -0400)]
aarch64: Consolidate NPTL/non versions of clone
At the same time, rely on non-clobbered registers across syscall
so that we eliminate the stack frame that we previously ignored
in the unwind info.
Marcus Shawcroft [Tue, 3 Jun 2014 12:25:34 +0000 (12:25 +0000)]
[AArch64] Regenerate libm-test-ulps
Wilco [Tue, 3 Jun 2014 08:10:39 +0000 (08:10 +0000)]
[AArch64] Switch from FE_TOWARDZERO to _FPU_FPCR_RM_MASK
Wilco [Tue, 3 Jun 2014 08:08:36 +0000 (08:08 +0000)]
[AArch64] Cleanup declarations in math_private.h.
Konstantin Serebryany [Tue, 3 Jun 2014 11:09:08 +0000 (16:39 +0530)]
Remove redundant nested function b64_from_24bit
Move multiple definitions of the nested function b64_from_24bit into a
single function __b64_from_24bit.
Roland McGrath [Mon, 2 Jun 2014 21:29:19 +0000 (14:29 -0700)]
SH: Consolidate NPTL/non versions of vfork
Siddhesh Poyarekar [Mon, 2 Jun 2014 18:05:09 +0000 (23:35 +0530)]
Fix format specifier for n_mmaps
Wilco [Mon, 2 Jun 2014 11:44:21 +0000 (12:44 +0100)]
[AArch64] Remove ISB after FPCR write.
Wilco [Mon, 2 Jun 2014 11:20:17 +0000 (12:20 +0100)]
[AArch64] Rewrite feupdateenv (BZ 17009).
David S. Miller [Mon, 2 Jun 2014 02:19:18 +0000 (19:19 -0700)]
Update Sparc ULPS.
* sysdeps/sparc/fpu/libm-test-ulps: Update.
David S. Miller [Sun, 25 May 2014 01:58:01 +0000 (18:58 -0700)]
Fix excessive ULP for y1_upward (0x2p+0) in test-float and test-ifloat.
* sysdeps/ieee754/flt-32/e_j1f.c (__ieee754_y1f): Force computations
to occur in round to nearest mode when |x| >= 2.0
Richard Henderson [Thu, 29 May 2014 16:14:49 +0000 (12:14 -0400)]
aarch64: Remove PSEUDO_RET
Richard Henderson [Thu, 29 May 2014 15:57:39 +0000 (11:57 -0400)]
aarch64: Fix error return from __ioctl
Forgotten in
ca3cfa40c16ef34c74951a07a57cfcbcd58898b1
where the error branch was moved from PSEUDO_RET.
Marko Myllynen [Fri, 30 May 2014 17:50:21 +0000 (10:50 -0700)]
Replace __int128 with __int128_t
* sysdeps/x86_64/link-defines.sym (BND_SIZE): Replace __int128
with __int128_t.
Siddhesh Poyarekar [Fri, 30 May 2014 17:14:45 +0000 (22:44 +0530)]
Fix formatting in malloc_info
Siddhesh Poyarekar [Fri, 30 May 2014 17:13:52 +0000 (22:43 +0530)]
Add mmap usage in malloc_info output
The current malloc_info xml output only has information about
allocations on the heap. Display information about number of mappings
and total mmapped size to this to complete the picture.
Roland McGrath [Fri, 16 May 2014 19:57:10 +0000 (12:57 -0700)]
m68k: Convert fork.c to arch-fork.h
Ondřej Bílka [Fri, 30 May 2014 11:24:56 +0000 (13:24 +0200)]
Remove mi_arena nested function.
Ondřej Bílka [Fri, 30 May 2014 11:23:39 +0000 (13:23 +0200)]
Richard Henderson [Thu, 22 May 2014 20:57:20 +0000 (16:57 -0400)]
aarch64: Rely on syscalls preserving registers
In several cases we've had asm routines rely on syscalls not clobbering
call-clobbered registers, and that's now deemed ABI. So take advantage
of this in the INLINE_SYSCALL path as well.
Shrinks libc.so by about 1k.
Richard Henderson [Tue, 20 May 2014 20:34:59 +0000 (16:34 -0400)]
aarch64: Use tpidr_el0 rather than __errno_location in librt
Richard Henderson [Tue, 20 May 2014 20:17:20 +0000 (16:17 -0400)]
aarch64: Use tpidr_el0 rather than __read_tp in librt
Richard Henderson [Sun, 25 May 2014 18:57:53 +0000 (14:57 -0400)]
aarch64: Improve syscall-cancel stack frame
One push instead of N; use stp/ldp to halve the insns.
Richard Henderson [Sun, 25 May 2014 18:15:14 +0000 (14:15 -0400)]
aarch64: Pass regno parameter to SINGLE_THREAD_P
Use cbz instead of cmp+b.eq.
Richard Henderson [Sun, 25 May 2014 18:07:17 +0000 (14:07 -0400)]
aarch64: Share code in syscall-cancel.h
Fold nocancel and error handling paths.
Richard Henderson [Sun, 25 May 2014 17:00:00 +0000 (13:00 -0400)]
aarch64: Tabify sysdep-cancel.h
Eric Wong [Thu, 29 May 2014 04:11:29 +0000 (09:41 +0530)]
Avoid stat/fstat in statvfs/fstatvfs (BZ #15132)
Delay the use of stat/fstat until stat data is required. When the
kernel returns ST_VALID, stat data is not used by __internal_statvfs.
Roland McGrath [Thu, 29 May 2014 00:23:19 +0000 (17:23 -0700)]
SH: Consolidate NPTL/non versions of clone
Roland McGrath [Wed, 28 May 2014 18:23:16 +0000 (14:23 -0400)]
tile: Convert fork.c to arch-fork.h
Roland McGrath [Tue, 27 May 2014 22:43:45 +0000 (15:43 -0700)]
IA64: Convert fork.c to arch-fork.h
Roland McGrath [Tue, 27 May 2014 19:58:01 +0000 (12:58 -0700)]
SH: Convert fork.c to arch-fork.h
Ondřej Bílka [Tue, 27 May 2014 14:56:11 +0000 (16:56 +0200)]
Remove duplicate code in elf/dl-deps.c.
Andreas Schwab [Tue, 13 May 2014 14:40:41 +0000 (16:40 +0200)]
Remove second argument from TLS_INIT_TP macro
Will Newton [Fri, 23 May 2014 14:24:30 +0000 (15:24 +0100)]
ARM: Fix handling of concurrent TLS descriptor resolution
The current code for handling concurrent resolution says that the
ABI for _dl_tlsdesc_resolve_hold is the same as that of
_dl_tlsdesc_lazy_resolver. However _dl_tlsdesc_resolve_hold is
called from the trampoline directly rather than the lazy resolver
stub so, for example, r2 has not been pushed so does not needed
to be restored.
This fixes an intermittent failure in nptl/tst-tls3 when building
glibc for arm-linux-gnueabihf with -mtls-dialect=gnu2.
ChangeLog:
2014-05-27 Will Newton <will.newton@linaro.org>
[BZ #16990]
* sysdeps/arm/dl-tlsdesc.S (_dl_tlsdesc_resolve_hold): Save
and restore r2 rather than just restoring.
Siddhesh Poyarekar [Tue, 27 May 2014 08:24:19 +0000 (13:54 +0530)]
Fix offset computation for append+ mode on switching from read (BZ #16724)
The offset computation in write mode uses the fact that _IO_read_end
is kept in sync with the external file offset. This however is not
true when O_APPEND is in effect since switching to write mode ought to
send the external file offset to the end of file without making the
necessary adjustment to _IO_read_end.
Hence in append mode, offset computation when writing should only
consider the effect of unflushed writes, i.e. from _IO_write_base to
_IO_write_ptr.
The wiki has a detailed document that describes the rationale for
offsets returned by ftell in various conditions:
https://sourceware.org/glibc/wiki/File%20offsets%20in%20a%20stdio%20stream%20and%20ftell
Adhemerval Zanella [Mon, 26 May 2014 17:40:08 +0000 (12:40 -0500)]
Update powerpc-fpu ULPs.
Adhemerval Zanella [Wed, 21 May 2014 21:08:06 +0000 (16:08 -0500)]
PowerPC: Move remaining nptl/sysdeps/unix/sysv/linux/powerpc/ files.
Adhemerval Zanella [Wed, 21 May 2014 21:06:30 +0000 (16:06 -0500)]
PowerPC: Move NPTL ABI headers to sysdeps.
Adhemerval Zanella [Fri, 23 May 2014 12:43:37 +0000 (07:43 -0500)]
PowerPC: Move powerpc64 timer_*.c out of nptl/
Adhemerval Zanella [Wed, 21 May 2014 01:31:04 +0000 (20:31 -0500)]
PowerPC: Consolidate NPTL/non versions of clone
Adhemerval Zanella [Mon, 26 May 2014 16:41:28 +0000 (11:41 -0500)]
PowerPC: Consolidate NPTL/non versions of vfork
Carlos O'Donell [Mon, 26 May 2014 13:54:59 +0000 (09:54 -0400)]
Remove nested function mi_arena from malloc_info.
The nested function mi_arena was removed from malloc_info
and made into a non-nested static inline function of the same
name with the correct set of arguments passed from malloc_info.
This enables building glibc with compilers that don't support
nested functions. Future work on malloc_info should remove these
functions entirely to support JSON format output. Therefore we
do the minimum required to remove the nested function.
Adhemerval Zanella [Thu, 22 May 2014 19:48:38 +0000 (14:48 -0500)]
PowerPC: Remove 64 bits instructions in PPC32 code
This patch replaces the insrdi by insrwi in powerpc32 assembly.
Andreas Schwab [Mon, 26 May 2014 10:31:13 +0000 (12:31 +0200)]
Fix searching localedef input on I18NPATH (BZ #16984)
Stefan Liebler [Mon, 26 May 2014 09:14:25 +0000 (11:14 +0200)]
Disable lock elision for PTHREAD_MUTEX_NORMAL.
Stefan Liebler [Mon, 26 May 2014 09:12:44 +0000 (11:12 +0200)]
Fix typo in tst-mutex5 ifndef -> ifdef
Siddhesh Poyarekar [Sat, 22 Feb 2014 04:39:27 +0000 (10:09 +0530)]
benchtests: Add new directive for benchmark initialization hook
Add a new 'init' directive that specifies the name of the function to
call to do function-specific initialization. This is useful for
benchmarks that need to do a one-time initialization before the
functions are executed.
Kyle McMartin [Mon, 26 May 2014 07:03:22 +0000 (12:33 +0530)]
[AARCH64] correct alignment of TLS_TCB_ALIGN (BZ #16796)
This fixes a variety of testsuite failures for me:
tststatic.out Error 1
tststatic2.out Error 1
tst-tls9-static.out Error 1
tst-audit8.out Error 127
tst-audit9.out Error 127
tst-audit1.out Error 127
and also has the added benefit of making LD_AUDIT/sotruss work on
AArch64.
Otherwise, we bail out early in _dl_try_allocate_static_tls as the
alignment requirement of the PT_TLS section in libc is 16.
Siddhesh Poyarekar [Mon, 26 May 2014 06:10:08 +0000 (11:40 +0530)]
Use NSS_STATUS_TRYAGAIN to indicate insufficient buffer (BZ #16878)
The netgroups nss modules in the glibc tree use NSS_STATUS_UNAVAIL
(with errno as ERANGE) when the supplied buffer does not have
sufficient space for the result. This is wrong, because the canonical
way to indicate insufficient buffer is to set the errno to ERANGE and
the status to NSS_STATUS_TRYAGAIN, as is used by all other modules.
This fixes nscd behaviour when the nss_ldap module returns
NSS_STATUS_TRYAGAIN to indicate that a netgroup entry is too long to
fit into the supplied buffer.
Richard Henderson [Fri, 23 May 2014 20:37:15 +0000 (16:37 -0400)]
arm,aarch64: Remove SINGLE_THREAD_P_PIC
This macro was removed by
2005-11-16 Daniel Jacobowitz <dan@codesourcery.com>
but not applied to the (still separate) eabi port so necro'd
when the eabi port superceded the old abi. It was thence
copied into the new AArch64 port.
Richard Henderson [Tue, 20 May 2014 18:40:22 +0000 (14:40 -0400)]
aarch64: Tidy syscall error check
Move the error branch from the PSEUDO_RET macro to the PSEUDO macro.
This is in line with other architectures, and will enable further improvments.
Richard Henderson [Thu, 22 May 2014 15:38:05 +0000 (11:38 -0400)]
aarch64: Remove DOARGS/UNDOARGS macros
While they do something for AArch32, they're useless for AArch64.
Richard Henderson [Sun, 25 May 2014 16:33:00 +0000 (12:33 -0400)]
aarch64: Fix DO_CALL block comment
Richard Henderson [Sun, 25 May 2014 16:04:54 +0000 (09:04 -0700)]
alpha: Do non-default symbols in pt-vfork.S
Richard Henderson [Fri, 23 May 2014 23:03:28 +0000 (16:03 -0700)]
Only provide non-default symbols in libpthread for vfork
* nptl/pt-vfork.c (vfork_resolve): Rename from vfork_ifunc.
(vfork, __vfork): Define via compat_symbol.
Richard Henderson [Fri, 23 May 2014 22:24:20 +0000 (15:24 -0700)]
Only support ifunc in nptl/pt-vfork.c
* nptl/pt-vfork.c: Error if !HAVE_IFUNC.
[!HAVE_IFUNC] (vfork_compat): Remove.
[!HAVE_IFUNC] (DEFINE_VFORK): Remove.
Joseph Myers [Fri, 23 May 2014 20:37:40 +0000 (20:37 +0000)]
Define TSVTX in tar.h for older POSIX (bug 16978).
As noted in bug 16978, older POSIX versions include
in the specified contents of <tar.h>, with only the 2001 edition
introducing the notion of XSI-conditional definitions and conditioning
that definition. Thus, this macro should be defined for
!__USE_XOPEN2K as well as for __USE_XOPEN, and this patch duly defines
it in that case. Tested x86_64.
[BZ #16978]
* posix/tar.h [!__USE_XOPEN2K] (TSVTX): Define macro.
* conform/Makefile (test-xfail-POSIX/tar.h/conform): Remove
variable.
Richard Henderson [Thu, 22 May 2014 15:51:13 +0000 (08:51 -0700)]
alpha: Move remaining files out of sysdeps/unix/sysv/linux/alpha/nptl/
Richard Henderson [Thu, 22 May 2014 03:31:38 +0000 (20:31 -0700)]
alpha: Consolidate NPTL/non versions of vfork
Richard Henderson [Wed, 21 May 2014 21:36:45 +0000 (14:36 -0700)]
alpha: Merge standard and nptl clone.S
Richard Henderson [Wed, 21 May 2014 18:58:13 +0000 (11:58 -0700)]
alpha: Remove nptl/fork.c
The merge at
ab21431318d99c94e644606dee1e6a4545d98007 failed
to properly remove the file.
Joseph Myers [Fri, 23 May 2014 12:07:50 +0000 (12:07 +0000)]
Fix log10 (1) in round-downward mode (bug 16977).
As with various other issues of this kind, bug 16977 is log10 (1)
wrongly returning -0 rather than +0 in round-downward mode because of
an implementation effectively in terms of log1p (x - 1). This patch
fixes the issue in the same way used for log.
Tested x86_64 and x86 and ulps updated accordingly. Also tested for
mips64 to confirm a fix was needed for ldbl-128 and to validate that
fix (also applied to ldbl-128ibm since that version of logl is
essentially the same as the ldbl-128 one).
[BZ #16977]
* sysdeps/i386/fpu/e_log10.S (__ieee754_log10): Take absolute
value when x - 1 is zero.
* sysdeps/i386/fpu/e_log10f.S (__ieee754_log10f): Likewise.
* sysdeps/i386/fpu/e_log10l.S (__ieee754_log10l): Likewise.
* sysdeps/ieee754/ldbl-128/e_log10l.c (__ieee754_log10l): Return
0.0L for an argument of 1.0L.
* sysdeps/ieee754/ldbl-128ibm/e_log10l.c (__ieee754_log10l):
Likewise.
* sysdeps/x86_64/fpu/e_log10l.S (__ieee754_log10l): Take absolute
value when x - 1 is zero.
* math/libm-test.inc (log10_test): Use ALL_RM_TEST.
* sysdeps/i386/fpu/libm-test-ulps: Update.
* sysdeps/x86_64/fpu/libm-test-ulps: Likewise.
Rasmus Villemoes [Tue, 20 May 2014 21:20:19 +0000 (23:20 +0200)]
manual: Update prototypes for alphasort and friends
The four functions {alpha,version}sort{,64} take parameters of type
const struct dirent{,64} **, not const void *.
Signed-off-by: Rasmus Villemoes <rv@rasmusvillemoes.dk>
Adhemerval Zanella [Thu, 22 May 2014 20:54:41 +0000 (15:54 -0500)]
PowerPC: Remove unneeded copysign[f] macros
This patch remove the unneeded copysign[f] macro from powerpc
math_private.h, since they are already covered in generic version.
Siddhesh Poyarekar [Thu, 22 May 2014 14:57:32 +0000 (20:27 +0530)]
Fix date in ChangeLog
Siddhesh Poyarekar [Thu, 22 May 2014 06:08:50 +0000 (11:38 +0530)]
Fix formatting
Konstantin Serebryany [Thu, 22 May 2014 02:59:00 +0000 (08:29 +0530)]
Remove nested functions: crypt/md5-crypt.c
This patch is the first in the series of patches that remove nested
functions from glibc.
Rationale: nested functions is a non-standard language feature;
removing nested functions
will allow to compile glibc with compilers other than GCC and thus
benefit from other compilers
and code analysis tools.
Adhemerval Zanella [Thu, 22 May 2014 12:53:44 +0000 (07:53 -0500)]
PowerPC: Fix memchr ifunc hidden symbol for PPC32
This patch fixes a similar issue to
736c304a1ab4cee36a2f3343f1698bc0abae4608, where for PPC32 if the symbol
is defined as hidden (memchr) then compiler will create a local branc
(symbol@local) and the linker will not create a required PLT call to
make the ifunc work. It changes the default hidden symbol (__GI_memchr)
to default memchr symbol for powerpc32 (__memchr_ppc32).
Roland McGrath [Fri, 16 May 2014 20:09:39 +0000 (13:09 -0700)]
AArch64: Convert fork.c to arch-fork.h
Joseph Myers [Wed, 21 May 2014 16:53:11 +0000 (16:53 +0000)]
Don't mention linuxthreads in Depend files.
I noticed that some of the Depend files, used to determine the
subdirectory build order in sysd-sorted, still mentioned linuxthreads,
although it hasn't been supported for many years. This patch removes
those references. In the case of nscd, it substitutes an nptl
reference, since I believe there is a fact a thread library dependence
there; the others already mentioned nptl.
Note that I am not at all confident in the completeness of these
Depend files.
Note also that references to linuxthreads remain in a comment in
sysdeps/unix/sysv/linux/ia64/Versions, and in manual/maint.texi,
manual/signal.texi and scripts/documented.sh.
Tested x86_64 that the installed shared libraries are unchanged by the
patch (as is sysd-sorted).
* nscd/Depend (linuxthreads): Remove.
(nptl): Add.
* resolv/Depend (linuxthreads): Remove.
* rt/Depend (linuxthreads): Remove.
Joseph Myers [Wed, 21 May 2014 16:52:08 +0000 (16:52 +0000)]
Consistently use $(elf-objpfx).
As previously noted
<https://sourceware.org/ml/libc-alpha/2013-05/msg00696.html>,
$(elf-objpfx) and $(elfobjdir) are redundant and should be
consolidated. This patch consolidates on $(elf-objpfx) (for
consistency with $(csu-objpfx)), also changing direct uses of
$(common-objpfx)elf/ to use $(elf-objpfx).
Tested x86_64, including that installed shared libraries are unchanged
by the patch.
* Makeconfig [$(build-hardcoded-path-in-tests) = yes]
(rtld-tests-LDFLAGS): Use $(elf-objpfx) instead of
$(common-objpfx)elf/.
(link-libc-before-gnulib): Likewise.
(elfobjdir): Remove variable.
* Makefile (install): Use $(elf-objpfx) instead of
$(common-objpfx)elf/.
* Makerules (link-libc-args): Use $(elf-objpfx) instead of
$(elfobjdir)/.
(link-libc-deps): Likewise.
($(common-objpfx)libc.so): Likewise.
($(common-objpfx)linkobj/libc.so): Likewise.
[$(cross-compiling) = no] (symbolic-link-prog): Use $(elf-objpfx)
instead of $(common-objpfx)elf/.
(symbolic-link-list): Likewise.
* iconvdata/Makefile ($(inst_gconvdir)/gconv-modules)
[$(cross-compiling) = no]: Likewise.
* sysdeps/arm/Makefile (gnulib-arch): Use $(elf-objpfx) instead of
$(elfobjdir)/.
(static-gnulib-arch): Likewise.
* sysdeps/s390/s390-64/Makefile ($(inst_gconvdir)/gconv-modules)
[$(cross-compiling) = no]: Use $(elf-objpfx) instead of
$(common-objpfx)elf/.
localedata/ChangeLog:
* Makefile (LOCALEDEF): Use $(elf-objpfx) instead of
$(common-objpfx)elf/.
Richard Henderson [Wed, 21 May 2014 15:36:51 +0000 (11:36 -0400)]
aarch64: Merge __local_multiple_threads offset with memory reference
This also highlights that we'd been loading 64-bits instead of
the proper 32-bits. Caught by the linker as a relocation error,
since the variable happened to be unaligned for 64-bits.
Richard Henderson [Wed, 21 May 2014 15:36:03 +0000 (11:36 -0400)]
aarch64: Merge rtld_errno offset with memory reference
Joseph Myers [Tue, 20 May 2014 21:27:13 +0000 (21:27 +0000)]
Fix ARM build with GCC trunk.
sysdeps/unix/sysv/linux/arm/unwind-resume.c and
sysdeps/unix/sysv/linux/arm/unwind-forcedunwind.c have static
variables that are written in C code but only read from toplevel asms.
Current GCC trunk now optimizes away such apparently write-only static
variables, so causing a build failure. This patch marks those
variables with __attribute_used__ to avoid that optimization.
Tested that this fixes the build for ARM.
* sysdeps/unix/sysv/linux/arm/unwind-forcedunwind.c
(libgcc_s_resume): Use __attribute_used__.
* sysdeps/unix/sysv/linux/arm/unwind-resume.c (libgcc_s_resume):
Likewise.
Adhemerval Zanella [Tue, 20 May 2014 21:21:51 +0000 (16:21 -0500)]
Update powerpc-fpu ULPs.
Adhemerval Zanella [Tue, 20 May 2014 21:07:49 +0000 (16:07 -0500)]
PowerPC: Fix copysignf optimization macro
This patch fixes the __copysignf optimized macro meant to internal libm
usage when used with constant value. Without the explicit cast to
float, if it is used with const double value (for instance, on
s_casinhf.c) double constants will be used and it may lead to precision
issues in some algorithms.
It fixes the following failures on PPC64/POWER7:
Failure: Test: Real part of: cacos_downward (inf + 0 i)
Result:
is: 1.
19209289550781250000e-07 0x1.00000000000000000000p-23
should be: 0.
00000000000000000000e+00 0x0.00000000000000000000p+0
Failure: Test: Real part of: cacos_downward (inf - 0 i)
Result:
is: 1.
19209289550781250000e-07 0x1.00000000000000000000p-23
should be: 0.
00000000000000000000e+00 0x0.00000000000000000000p+0
Failure: Test: Real part of: cacos_downward (inf + 0.5 i)
Result:
is: 1.
19209289550781250000e-07 0x1.00000000000000000000p-23
should be: 0.
00000000000000000000e+00 0x0.00000000000000000000p+0
Failure: Test: Real part of: cacos_downward (inf - 0.5 i)
Result:
is: 1.
19209289550781250000e-07 0x1.00000000000000000000p-23
should be: 0.
00000000000000000000e+00 0x0.00000000000000000000p+0
Failure: Test: Real part of: cacos_towardzero (inf + 0 i)
Result:
is: 1.
19209289550781250000e-07 0x1.00000000000000000000p-23
should be: 0.
00000000000000000000e+00 0x0.00000000000000000000p+0
Failure: Test: Real part of: cacos_towardzero (inf - 0 i)
Result:
is: 1.
19209289550781250000e-07 0x1.00000000000000000000p-23
should be: 0.
00000000000000000000e+00 0x0.00000000000000000000p+0
Failure: Test: Real part of: cacos_towardzero (inf + 0.5 i)
Result:
is: 1.
19209289550781250000e-07 0x1.00000000000000000000p-23
should be: 0.
00000000000000000000e+00 0x0.00000000000000000000p+0
Failure: Test: Real part of: cacos_towardzero (inf - 0.5 i)
Result:
is: 1.
19209289550781250000e-07 0x1.00000000000000000000p-23
should be: 0.
00000000000000000000e+00 0x0.00000000000000000000p+0
Aurelien Jarno [Tue, 20 May 2014 12:41:44 +0000 (14:41 +0200)]
Fix strtold on 32-bit sparc (and probably others) (BZ #16965)
This patch fixes an issue observed running the tst-strtod-round test on
32 bit sparc. In some conditions, strtold calls round_and_return, which in
turn calls __mpn_rshift with cnt = 0, while stdlib/rshift.c explicitly says
that cnts should satisfy 0 < CNT < BITS_PER_MP_LIMB. In this case, the code
end up doing a logical shift right of the same amount than the register,
which is undefined in the C standard.
Due to this bug, 32-bit sparc does not correctly convert the value
"0x1p-16446", but it is likely that other architectures are also
affected for other input values.
Aurelien Jarno [Thu, 15 May 2014 22:06:54 +0000 (00:06 +0200)]
fix nl_langinfo with static linking (BZ #16915)
For static linking the locale code avoids linking code and data for
unused categories. However for nl_langinfo we know only at runtime which
categories are used, so direct reference to every nl_current_CATEGORY
symbol should be done.
This was broken by commit
bc3e1c127392da88d0c8bf2ae728147982a3d1bc where
nl_langinfo_l and nl_langinfo have been merged and some code has been
lost in the process.
In order to detect locales issues with static linking, compile a version
of tst-langinfo with static linking.
Note: this is Debian bug#747103 reported by Raphael <raphael.astier@eliot-sa.com>
Richard Henderson [Tue, 20 May 2014 14:15:46 +0000 (07:15 -0700)]
alpha: fix sa_flags type (BZ 16967)
Richard Henderson [Tue, 20 May 2014 13:59:52 +0000 (06:59 -0700)]
alpha: Remove bits/siginfo.h (BZ 16966)
Using the default header instead. This matches the kernel, which also
uses the generic header. Fixes the sys/wait.h conform issue, where
si_band had the wrong type.
Richard Henderson [Mon, 19 May 2014 05:09:30 +0000 (22:09 -0700)]
alpha: Define ELF_MACHINE_NO_RELA
Will Newton [Mon, 19 May 2014 13:38:30 +0000 (14:38 +0100)]
AArch64: Fix handling of nocancel syscall failures
The current code for nocancel syscalls does not do a comparison of
the system call return value. This leads to code being generated
where the b.cs follows the svc instruction directly without setting
the flags on which the branch depends.
ChangeLog:
2014-05-20 Will Newton <will.newton@linaro.org>
* sysdeps/unix/sysv/linux/aarch64/nptl/sysdep-cancel.h (PSEUDO):
Test the return value of the system call in the nocancel case.
Yvan Roux [Tue, 20 May 2014 12:45:22 +0000 (13:45 +0100)]
AArch64: Remove asm/ptrace.h inclusion in sys/user.h and sys/procfs.h
This patch fixes an issue observed by the Xen project, where including
signal.h exposes various PSR_MODE #defines. This is due to the usage
in sys/user.h and sys/procfs.h of the struct user_pt_regs and
user_fpsimd_state included via asm/ptrace.h. The namespace pollution
this inclusion introduce is already partially fixed with some #undef
of the PTRACE_* symbols, but other symbols like the PSR_MODE ones are
still present, and undefining them is not safe since a user can
include ptrace.h before user.h.
My proposition is to define the 2 structures we need in user.h and get
rid of the asm/ptrace.h inclusion.
Build and make check are clean on AArch64.
2014-05-20 Will Newton <will.newton@linaro.org>
Yvan Roux <yvan.roux@linaro.org>
* sysdeps/unix/sysv/linux/aarch64/sys/user.h: Remove unused
#include of asm/ptrace.h.
(PTRACE_GET_THREAD_AREA): Remove #undef.
(PTRACE_GETHBPREGS): Likewise.
(PTRACE_SETHBPREGS): Likewise.
(struct user_regs_struct): New structure.
(struct user_fpsimd_struct): New structure.
* sysdeps/unix/sysv/linux/aarch64/sys/procfs.h: Remove unused
#include of asm/ptrace.h and second #include of sys/user.h.
(PTRACE_GET_THREAD_AREA): Remove #undef.
(PTRACE_GETHBPREGS): Likewise.
(PTRACE_SETHBPREGS): Likewise.
(ELF_NGREG): Use new struct user_regs_struct.
(elf_fpregset_t): Use new struct user_fpsimd_struct.
Adhemerval Zanella [Mon, 19 May 2014 22:56:55 +0000 (17:56 -0500)]
PowerPC: Fix multiarch hypotf PPC64 path
This patch moves the hypotf multiarch implementation to correct path.
Marcus Shawcroft [Mon, 19 May 2014 08:08:59 +0000 (09:08 +0100)]
Revert "ARM: Improve fenv implementation"
This reverts commit
c0c08d02c82275353f5c556f935a1a01714d9d7f.
Jose E. Marchesi [Sat, 17 May 2014 18:20:27 +0000 (11:20 -0700)]
Fix sparc memcpy data corruption when using niagara2 optimized routines.
* sysdeps/sparc/sparc64/multiarch/memcpy-niagara2.S: Add missing
membar to avoid block loads/stores to overlap previous stores.
Richard Henderson [Sat, 17 May 2014 18:25:19 +0000 (11:25 -0700)]
alpha: Create __syscall_nocancel entry points
Richard Henderson [Sat, 17 May 2014 18:20:44 +0000 (11:20 -0700)]
Merge remote-tracking branch 'origin/roland/nptl-alpha'
David S. Miller [Sat, 17 May 2014 18:11:53 +0000 (11:11 -0700)]
Fix some termios.h conformtest failures on sparc.
* sysdeps/unix/sysv/linux/sparc/bits/termios.h (PAGEOUT, WRAP):
Protect with __USE_GNU.
(TIOCSET_TEMPT): Likewise.
(TIOCM_LE, TIOCM_DTR, TIOCM_RTS, TIOCM_ST, TIOCM_SR, TIOCM_CTS,
TIOCM_CAR, TIOCM_RNG, TIOCM_DSR, TIOCM_CD, TIOCM_RI): Remove as
these are already provided in bits/ioctl-types.h
Roland McGrath [Fri, 16 May 2014 21:00:35 +0000 (14:00 -0700)]
Fix __waitpid_nocancel link error.