]> git.ipfire.org Git - thirdparty/glibc.git/log
thirdparty/glibc.git
6 years agoUpdate for 2.27 release glibc-2.27
Dmitry V. Levin [Thu, 1 Feb 2018 16:17:18 +0000 (16:17 +0000)] 
Update for 2.27 release

6 years agoFix ChangeLog formatting
Dmitry V. Levin [Thu, 1 Feb 2018 16:17:18 +0000 (16:17 +0000)] 
Fix ChangeLog formatting

6 years agoNEWS: add the list of bugs fixed in 2.27
Dmitry V. Levin [Thu, 1 Feb 2018 16:17:18 +0000 (16:17 +0000)] 
NEWS: add the list of bugs fixed in 2.27

6 years agoRecord CVE-2018-6485 in ChangeLog and NEWS [BZ #22343]
Florian Weimer [Thu, 1 Feb 2018 14:00:44 +0000 (15:00 +0100)] 
Record CVE-2018-6485 in ChangeLog and NEWS [BZ #22343]

6 years agostdlib: Fixing test-*atexit*-race tests on ia64
Adhemerval Zanella [Thu, 1 Feb 2018 12:31:57 +0000 (10:31 -0200)] 
stdlib: Fixing test-*atexit*-race tests on ia64

These tests require a new thread stack size set to a value (0x20000)
lower than the architecture minimum (0x30000).  Set the stack size
to PTHREAD_STACK_MIN in this case.

Checked on ia64-linux-gnu.

* stdlib/test-atexit-race-common.c (do_test): Check stack size
against PTHREAD_STACK_MIN.

6 years agoUpdate contributions in the manual
Dmitry V. Levin [Thu, 1 Feb 2018 13:07:39 +0000 (13:07 +0000)] 
Update contributions in the manual

* manual/contrib.texi (Palmer Dabbelt, Arjun Shankar, Florian Weimer):
New entries.
(Rafal Luzynski, Andreas Schwab): Update.

6 years agoNEWS: List the languages which use the alternative months.
Rafal Luzynski [Thu, 1 Feb 2018 00:45:43 +0000 (01:45 +0100)] 
NEWS: List the languages which use the alternative months.

[BZ #10871]
* NEWS: List the languages which actually use the alternative
months feature in this release.  Also explain that "alt_mon" and
"ab_alt_mon" are optional.

6 years agocrypt: Fix badsalttest test (Bug 22765)
Il'ya Malakhov [Wed, 31 Jan 2018 22:32:19 +0000 (14:32 -0800)] 
crypt: Fix badsalttest test (Bug 22765)

The value of 'cd.initialized' is left uninitialized before the
first invocation of 'crypt_r ()' in this test despite the fact
that it should be set to zero according to the API.

Reviewed-by: Carlos O'Donell <carlos@redhat.com>
6 years agoFix typo in the previous commit
Dmitry V. Levin [Wed, 31 Jan 2018 23:13:00 +0000 (23:13 +0000)] 
Fix typo in the previous commit

The version of GCC was 7.3, not 7.3.1.

6 years agoUpdate information about the newest versions of tools used to build glibc
Dmitry V. Levin [Wed, 31 Jan 2018 14:20:10 +0000 (14:20 +0000)] 
Update information about the newest versions of tools used to build glibc

* manual/install.texi (Tools for Compilation): Update the newest
versions of gcc, binutils, texinfo, gawk, bison, and sed.
* INSTALL: Regenerated.

6 years agoallocalim.h: use __glibc_likely instead of __builtin_expect
Samuel Thibault [Tue, 30 Jan 2018 20:42:21 +0000 (21:42 +0100)] 
allocalim.h: use __glibc_likely instead of __builtin_expect

* sysdeps/pthread/allocalim.h (__libc_use_alloca): Use __glibc_likely
instead of __builtin_expect.

6 years agohurd: Fix ChangeLog date
Samuel Thibault [Tue, 30 Jan 2018 18:56:07 +0000 (19:56 +0100)] 
hurd: Fix ChangeLog date

6 years agonss: Adjust tests to use nss_files only
Florian Weimer [Tue, 30 Jan 2018 05:28:49 +0000 (06:28 +0100)] 
nss: Adjust tests to use nss_files only

6 years agohr_HR: Add alternative month names (bug 10871).
Rafal Luzynski [Tue, 30 Jan 2018 11:33:14 +0000 (12:33 +0100)] 
hr_HR: Add alternative month names (bug 10871).

[BZ #10871]
* localedata/locales/hr_HR (mon): Rename to...
(alt_mon): This.
(mon): Import from CLDR (genitive case).
(d_t_fmt): Update the comment.

6 years agohurd: include generic's hp-timing.h instead of copying it
Samuel Thibault [Tue, 30 Jan 2018 00:17:51 +0000 (01:17 +0100)] 
hurd: include generic's hp-timing.h instead of copying it

* sysdeps/mach/hurd/hp-timing.h: include <sysdeps/generic/hp-timing.h>
instead of copying it.

6 years agohurd: Add tlsdesc.sym
Samuel Thibault [Mon, 29 Jan 2018 23:52:48 +0000 (00:52 +0100)] 
hurd: Add tlsdesc.sym

* sysdeps/mach/hurd/i386/tlsdesc.sym: New file.

6 years agohurd: disable hp timing
Samuel Thibault [Mon, 29 Jan 2018 23:47:31 +0000 (00:47 +0100)] 
hurd: disable hp timing

We don't have support for hp timing for now, even the i686 variant, which needs
to know the CPU speed.
Copied from sysdeps/generic/hp-timing.h

* sysdeps/mach/hurd/hp-timing.h: New file.

6 years agohurd: Fix comments for FREAD and FWRITE
Samuel Thibault [Mon, 29 Jan 2018 21:56:03 +0000 (22:56 +0100)] 
hurd: Fix comments for FREAD and FWRITE

* bits/fcntl.h: Fix comment for FREAD and FWRITE.
* sysdeps/mach/hurd/bits/fcntl.h: Likewise.

6 years agomalloc: Use assert.h's assert macro
Samuel Thibault [Mon, 29 Jan 2018 21:49:45 +0000 (22:49 +0100)] 
malloc: Use assert.h's assert macro

This avoids assert definition conflicts if some of the headers used by
malloc.c happens to include assert.h.  Malloc still needs a malloc-avoiding
implementation, which we get by redirecting __assert_fail to malloc's
__malloc_assert.

* malloc/malloc.c: Include <assert.h>.
(assert): Do not define.
[!defined NDEBUG] (__assert_fail): Define to __malloc_assert.

6 years agolibio: Rename _FWRITE to FWRITE_FUNC
Samuel Thibault [Mon, 29 Jan 2018 21:44:46 +0000 (22:44 +0100)] 
libio: Rename _FWRITE to FWRITE_FUNC

_FWRITE would be in the reserved-namespace.

* libio/tst-memstream3.c (_FWRITE): Rename to FWRITE_FUNC.
(do_test_bz20181): Rename accordingly.

6 years agoallocalim.h: Fix codestyle
Samuel Thibault [Mon, 29 Jan 2018 21:21:46 +0000 (22:21 +0100)] 
allocalim.h: Fix codestyle

* sysdeps/pthread/allocalim.h (__libc_use_alloca): Commute operands of
|| to respect codestyle.

6 years agohurd: Fix ChangeLog date
Samuel Thibault [Mon, 29 Jan 2018 21:19:14 +0000 (22:19 +0100)] 
hurd: Fix ChangeLog date

6 years agohurd: Fix preprocessor indentation
Samuel Thibault [Mon, 29 Jan 2018 21:17:11 +0000 (22:17 +0100)] 
hurd: Fix preprocessor indentation

6 years agoReject invalid definitions of _POSIX_CHOWN_RESTRICTED, _POSIX_NO_TRUNC, _POSIX_VDISABLE
Andreas Schwab [Sun, 28 Jan 2018 17:48:04 +0000 (18:48 +0100)] 
Reject invalid definitions of _POSIX_CHOWN_RESTRICTED, _POSIX_NO_TRUNC, _POSIX_VDISABLE

POSIX requires that the constants _POSIX_CHOWN_RESTRICTED,
_POSIX_NO_TRUNC, and _POSIX_VDISABLE are always defined to a value other
than -1.

6 years agohurd: Add expected ABI lists
Samuel Thibault [Sun, 28 Jan 2018 22:30:15 +0000 (23:30 +0100)] 
hurd: Add expected ABI lists

* hurd/Versions: Fix version when _hurd_exec_paths was added.
* mach/Versions: Fix version when __mach_host_self_ was added.
* sysdeps/mach/hurd/i386/ld.abilist: New file.
* sysdeps/mach/hurd/i386/libBrokenLocale.abilist: New file.
* sysdeps/mach/hurd/i386/libanl.abilist: New file.
* sysdeps/mach/hurd/i386/libc.abilist: New file.
* sysdeps/mach/hurd/i386/libcrypt.abilist: New file.
* sysdeps/mach/hurd/i386/libdl.abilist: New file.
* sysdeps/mach/hurd/i386/libm.abilist: New file.
* sysdeps/mach/hurd/i386/libnsl.abilist: New file.
* sysdeps/mach/hurd/i386/libresolv.abilist: New file.
* sysdeps/mach/hurd/i386/librt.abilist: New file.
* sysdeps/mach/hurd/i386/libutil.abilist: New file.

6 years agoRISC-V: Add ipc_priv.h
Palmer Dabbelt [Mon, 29 Jan 2018 17:32:37 +0000 (09:32 -0800)] 
RISC-V: Add ipc_priv.h

This contains a definition of __IPC_64 that matches the RISC-V Linux
ABI.

2018-01-29  Darius Rad  <darius@bluespec.com>

        * sysdeps/unix/sysv/linux/riscv/ipc_priv.h: New file.

6 years agoAdd RISC-V to build-many-glibcs.py
Palmer Dabbelt [Mon, 29 Jan 2018 18:30:51 +0000 (10:30 -0800)] 
Add RISC-V to build-many-glibcs.py

For full disclosure, I've only run build-many-glibcs.py with the
additional diff below.

    diff --git a/scripts/build-many-glibcs.py b/scripts/build-many-glibcs.py
    index 1c7b85050b57..22cc7b427041 100755
    --- a/scripts/build-many-glibcs.py
    +++ b/scripts/build-many-glibcs.py
    @@ -706,7 +706,7 @@ class Context(object):
                                 'gcc': 'vcs-7',
                                 'glibc': 'vcs-mainline',
                                 'gmp': '6.1.2',
    -                            'linux': '4.14',
    +                            'linux': '4.15-rc8',
                                 'mpc': '1.0.3',
                                 'mpfr': '3.1.6'}
             use_versions = {}
    @@ -841,7 +841,7 @@ class Context(object):
             url_map = {'binutils':
    'https://ftp.gnu.org/gnu/binutils/binutils-%(version)s.tar.bz2',
                        'gcc':
    'https://ftp.gnu.org/gnu/gcc/gcc-%(version)s/gcc-%(version)s.tar.bz2',
                        'gmp':
    'https://ftp.gnu.org/gnu/gmp/gmp-%(version)s.tar.xz',
    -                   'linux':
                        'https://www.kernel.org/pub/linux/kernel/v4.x/linux-%(version)s.tar.xz',
    +                   'linux':
    'https://git.kernel.org/torvalds/t/linux-%(version)s.tar.gz',
                        'mpc':
    'https://ftp.gnu.org/gnu/mpc/mpc-%(version)s.tar.gz',
                        'mpfr':
    'https://ftp.gnu.org/gnu/mpfr/mpfr-%(version)s.tar.xz'}
             if component not in url_map:

2018-01-29  Palmer Dabbelt  <palmer@sifive.com>

        * scripts/build-many-glibcs.py (Context): Add RISC-V targets.
        (Config): Likewise.

6 years agoRISC-V: Build Infastructure
Palmer Dabbelt [Mon, 29 Jan 2018 18:30:24 +0000 (10:30 -0800)] 
RISC-V: Build Infastructure

This patch lays out the top-level orginazition of the RISC-V port.  It
contains all the Implies files as well as various other fragments of
build infastructure for the RISC-V port.  This contains the only change
to a shared file: config.h.in.

RISC-V is a family of base ISAs with optional extensions.  The base ISAs
are RV32I and RV64I, which are 32-bit and 64-bit integer-only ISAs, but
this port currently only supports RV64I based systems.  Support for
RISC-V lives in in sysdeps/riscv.  In addition to these ISAs, our glibc
port supports most of the currently-defined extensions: the A extension
for atomics, the M extension for multiplication, the C extension for
compressed instructions, and the F/D extensions for single/double
precision IEEE floating-point.  Most of these extensions are handled by
GCC, but glibc defines various floating-point wrappers and emulation
routines as well as some atomic wrappers.

We support running glibc-based programs on Linux, the support for which
lives in sysdeps/unix/sysv/linux/riscv.

2018-01-29  Palmer Dabbelt  <palmer@sifive.com>

        * sysdeps/riscv/Implies: New file.
        * sysdeps/riscv/Makefile: Likewise.
        * sysdeps/riscv/configure: Likewise.
        * sysdeps/riscv/configure.ac: Likewise.
        * sysdeps/riscv/nptl/Makefile: Likewise.
        * sysdeps/riscv/preconfigure: Likewise.
        * sysdeps/riscv/rv64/Implies-after: Likewise.
        * sysdeps/riscv/rv64/rvd/Implies: Likewise.
        * sysdeps/riscv/rv64/rvf/Implies: Likewise.
        * sysdeps/unix/sysv/linux/riscv/Implies: Likewise.
        * sysdeps/unix/sysv/linux/riscv/Makefile: Likewise.
        * sysdeps/unix/sysv/linux/riscv/Versions: Likewise.
        * sysdeps/unix/sysv/linux/riscv/configure: Likewise.
        * sysdeps/unix/sysv/linux/riscv/configure.ac: Likewise.
        * sysdeps/unix/sysv/linux/riscv/ldd-rewrite.sed: Likewise.
        * sysdeps/unix/sysv/linux/riscv/rv64/Implies: Likewise.
        * sysdeps/unix/sysv/linux/riscv/rv64/Makefile: Likewise.
        * sysdeps/unix/sysv/linux/riscv/shlib-versions: Likewise.

6 years agoRISC-V: Add ABI Lists
Palmer Dabbelt [Mon, 29 Jan 2018 18:29:57 +0000 (10:29 -0800)] 
RISC-V: Add ABI Lists

I started with the aarch64 ABI lists and manually went through each
difference, ensuring that the missing entries had been deprecated along
the line.  Darius generated the ulps files by running the test cases on QEMU.

2018-01-29  Palmer Dabbelt  <palmer@sifive.com>

        * sysdeps/riscv/nofpu/libm-test-ulps: New file.
        * sysdeps/riscv/nofpu/libm-test-ulps-name: Likewise.
        * sysdeps/riscv/rv64/rvd/libm-test-ulps: Likewise.
        * sysdeps/riscv/rv64/rvd/libm-test-ulps-name: Likewise.
        * sysdeps/unix/sysv/linux/riscv/localplt.data: Likewise.
        * sysdeps/unix/sysv/linux/riscv/rv64/c++-types.data: Likewise.
        * sysdeps/unix/sysv/linux/riscv/rv64/ld.abilist: Likewise.
        * sysdeps/unix/sysv/linux/riscv/rv64/libanl.abilist: Likewise.
        * sysdeps/unix/sysv/linux/riscv/rv64/libc.abilist: Likewise.
        * sysdeps/unix/sysv/linux/riscv/rv64/libdl.abilist: Likewise.
        * sysdeps/unix/sysv/linux/riscv/rv64/libm.abilist: Likewise.
        * sysdeps/unix/sysv/linux/riscv/rv64/libnsl.abilist: Likewise.
        * sysdeps/unix/sysv/linux/riscv/rv64/librt.abilist: Likewise.
        * sysdeps/unix/sysv/linux/riscv/rv64/libutil.abilist: Likewise.

6 years agoRISC-V: Linux Startup and Dynamic Loading Code
Palmer Dabbelt [Mon, 29 Jan 2018 18:29:13 +0000 (10:29 -0800)] 
RISC-V: Linux Startup and Dynamic Loading Code

This contains the Linux-specific code for loading programs on RISC-V.

2018-01-29  Palmer Dabbelt  <palmer@sifive.com>

        * sysdeps/unix/sysv/linux/riscv/dl-static.c: New file.
        * sysdeps/unix/sysv/linux/riscv/ldconfig.h: Likewise.
        * sysdeps/unix/sysv/linux/riscv/ldsodefs.h: Likewise.

6 years agoRISC-V: Linux ABI
Palmer Dabbelt [Mon, 29 Jan 2018 18:28:32 +0000 (10:28 -0800)] 
RISC-V: Linux ABI

Linux-specific code that is required for maintaining ABI compatibility.
This doesn't contain the actual system call interface, that is split out
in order to avoid having a patch that's too big.

2018-01-29  Palmer Dabbelt  <palmer@sifive.com>

        * sysdeps/riscv/nptl/pthread-offsets.h: New file.
        * sysdeps/riscv/nptl/pthreaddef.h: Likewise.
        * sysdeps/unix/sysv/linux/riscv/bits/fcntl.h: Likewise.
        * sysdeps/unix/sysv/linux/riscv/bits/mman.h: Likewise.
        * sysdeps/unix/sysv/linux/riscv/bits/sigcontext.h: Likewise.
        * sysdeps/unix/sysv/linux/riscv/dl-cache.h: Likewise.
        * sysdeps/unix/sysv/linux/riscv/flush-icache.c: Likewise.
        * sysdeps/unix/sysv/linux/riscv/getcontext.S: Likewise.
        * sysdeps/unix/sysv/linux/riscv/init-first.c: Likewise.
        * sysdeps/unix/sysv/linux/riscv/libc-vdso.h: Likewise.
        * sysdeps/unix/sysv/linux/riscv/makecontext.c: Likewise.
        * sysdeps/unix/sysv/linux/riscv/readelflib.c: Likewise.
        * sysdeps/unix/sysv/linux/riscv/register-dump.h: Likewise.
        * sysdeps/unix/sysv/linux/riscv/setcontext.S: Likewise.
        * sysdeps/unix/sysv/linux/riscv/sigcontextinfo.h: Likewise.
        * sysdeps/unix/sysv/linux/riscv/swapcontext.S: Likewise.
        * sysdeps/unix/sysv/linux/riscv/sys/cachectl.h: Likewise.
        * sysdeps/unix/sysv/linux/riscv/sys/procfs.h: Likewise.
        * sysdeps/unix/sysv/linux/riscv/sys/ucontext.h: Likewise.
        * sysdeps/unix/sysv/linux/riscv/sys/user.h: Likewise.
        * sysdeps/unix/sysv/linux/riscv/ucontext-macros.h: Likewise.
        * sysdeps/unix/sysv/linux/riscv/ucontext_i.sym: Likewise.

6 years agoRISC-V: Linux Syscall Interface
Palmer Dabbelt [Mon, 29 Jan 2018 18:27:52 +0000 (10:27 -0800)] 
RISC-V: Linux Syscall Interface

Contains the Linux system call interface, as well as the definitions of
a handful of system calls.

2018-01-29  Palmer Dabbelt  <palmer@sifive.com>

        * sysdeps/riscv/nptl/nptl-sysdep.S: New file.
        * sysdeps/unix/sysv/linux/riscv/arch-fork.h: Likewise.
        * sysdeps/unix/sysv/linux/riscv/clone.S: Likewise.
        * sysdeps/unix/sysv/linux/riscv/profil-counter.h: Likewise.
        * sysdeps/unix/sysv/linux/riscv/pt-vfork.S: Likewise.
        * sysdeps/unix/sysv/linux/riscv/syscall.c: Likewise.
        * sysdeps/unix/sysv/linux/riscv/sysdep.S: Likewise.
        * sysdeps/unix/sysv/linux/riscv/sysdep.h: Likewise.
        * sysdeps/unix/sysv/linux/riscv/vfork.S: Likewise.

6 years agoRISC-V: Atomic and Locking Routines
Palmer Dabbelt [Mon, 29 Jan 2018 18:27:17 +0000 (10:27 -0800)] 
RISC-V: Atomic and Locking Routines

This patch implements various atomic and locking routines on RISC-V.  We
mandate the A extension on Linux-capable RISC-V systems, so this can
rely on always having the various atomic instructions availiable.

2018-01-29  Palmer Dabbelt  <palmer@sifive.com>

        * sysdeps/riscv/nptl/bits/pthreadtypes-arch.h: New file.
        * sysdeps/riscv/nptl/bits/semaphore.h: Likewise.
        * sysdeps/riscv/nptl/libc-lowlevellock.c: Likewise.
        * sysdeps/unix/sysv/linux/riscv/atomic-machine.h: Likewise.

6 years agoRISC-V: Hard Float Support
Palmer Dabbelt [Mon, 29 Jan 2018 17:27:10 +0000 (09:27 -0800)] 
RISC-V: Hard Float Support

This patch contains hardware floating-point support for the RISC-V ISA.
While we currently only support hard-float systems with both the F and D
extensions, I've left the F-specific code split out into seperate
folders in order to ease adding support for F-only and RV32I-based
systems in the future.  I gave this a quick once-over and believe I've
removed all the code that implements RV32IF, RV32IFD, and RV64IF
targets.

2018-01-29  Palmer Dabbelt  <palmer@sifive.com>

        * sysdeps/riscv/rv64/rvd/s_ceil.c: New file.
        * sysdeps/riscv/rv64/rvd/s_floor.c: Likewise.
        * sysdeps/riscv/rv64/rvd/s_llrint.c: Likewise.
        * sysdeps/riscv/rv64/rvd/s_llround.c: Likewise.
        * sysdeps/riscv/rv64/rvd/s_lrint.c: Likewise.
        * sysdeps/riscv/rv64/rvd/s_lround.c: Likewise.
        * sysdeps/riscv/rv64/rvd/s_nearbyint.c: Likewise.
        * sysdeps/riscv/rv64/rvd/s_rint.c: Likewise.
        * sysdeps/riscv/rv64/rvd/s_round.c: Likewise.
        * sysdeps/riscv/rv64/rvd/s_roundeven.c: Likewise.
        * sysdeps/riscv/rv64/rvd/s_trunc.c: Likewise.
        * sysdeps/riscv/rv64/rvf/s_llrintf.c: Likewise.
        * sysdeps/riscv/rv64/rvf/s_llroundf.c: Likewise.
        * sysdeps/riscv/rv64/rvf/s_lrintf.c: Likewise.
        * sysdeps/riscv/rv64/rvf/s_lroundf.c: Likewise.
        * sysdeps/riscv/rvd/e_sqrt.c: Likewise.
        * sysdeps/riscv/rvd/s_copysign.c: Likewise.
        * sysdeps/riscv/rvd/s_finite.c: Likewise.
        * sysdeps/riscv/rvd/s_fma.c: Likewise.
        * sysdeps/riscv/rvd/s_fmax.c: Likewise.
        * sysdeps/riscv/rvd/s_fmin.c: Likewise.
        * sysdeps/riscv/rvd/s_fpclassify.c: Likewise.
        * sysdeps/riscv/rvd/s_isinf.c: Likewise.
        * sysdeps/riscv/rvd/s_isnan.c: Likewise.
        * sysdeps/riscv/rvd/s_issignaling.c: Likewise.
        * sysdeps/riscv/rvf/e_sqrtf.c: Likewise.
        * sysdeps/riscv/rvf/fclrexcpt.c: Likewise.
        * sysdeps/riscv/rvf/fegetenv.c: Likewise.
        * sysdeps/riscv/rvf/fegetmode.c: Likewise.
        * sysdeps/riscv/rvf/fegetround.c: Likewise.
        * sysdeps/riscv/rvf/feholdexcpt.c: Likewise.
        * sysdeps/riscv/rvf/fesetenv.c: Likewise.
        * sysdeps/riscv/rvf/fesetexcept.c: Likewise.
        * sysdeps/riscv/rvf/fesetmode.c: Likewise.
        * sysdeps/riscv/rvf/fesetround.c: Likewise.
        * sysdeps/riscv/rvf/feupdateenv.c: Likewise.
        * sysdeps/riscv/rvf/fgetexcptflg.c: Likewise.
        * sysdeps/riscv/rvf/fraiseexcpt.c: Likewise.
        * sysdeps/riscv/rvf/fsetexcptflg.c: Likewise.
        * sysdeps/riscv/rvf/ftestexcept.c: Likewise.
        * sysdeps/riscv/rvf/get-rounding-mode.h: Likewise.
        * sysdeps/riscv/rvf/math_private.h: Likewise.
        * sysdeps/riscv/rvf/s_ceilf.c: Likewise.
        * sysdeps/riscv/rvf/s_copysignf.c: Likewise.
        * sysdeps/riscv/rvf/s_finitef.c: Likewise.
        * sysdeps/riscv/rvf/s_floorf.c: Likewise.
        * sysdeps/riscv/rvf/s_fmaf.c: Likewise.
        * sysdeps/riscv/rvf/s_fmaxf.c: Likewise.
        * sysdeps/riscv/rvf/s_fminf.c: Likewise.
        * sysdeps/riscv/rvf/s_fpclassifyf.c: Likewise.
        * sysdeps/riscv/rvf/s_isinff.c: Likewise.
        * sysdeps/riscv/rvf/s_isnanf.c: Likewise.
        * sysdeps/riscv/rvf/s_issignalingf.c: Likewise.
        * sysdeps/riscv/rvf/s_nearbyintf.c: Likewise.
        * sysdeps/riscv/rvf/s_rintf.c: Likewise.
        * sysdeps/riscv/rvf/s_roundevenf.c: Likewise.
        * sysdeps/riscv/rvf/s_roundf.c: Likewise.
        * sysdeps/riscv/rvf/s_truncf.c: Likewise.

6 years agoRISC-V: Generic <math.h> and soft-fp Routines
Palmer Dabbelt [Mon, 29 Jan 2018 18:26:35 +0000 (10:26 -0800)] 
RISC-V: Generic <math.h> and soft-fp Routines

This patch contains the miscellaneous math routines and headers we have
implemented for RISC-V.  This includes things from <math.h> that aren't
completely ISA-generic, floating-point bit manipulation, and soft-fp
hooks.

2018-01-29  Palmer Dabbelt  <palmer@sifive.com>

        * sysdeps/riscv/bits/fenv.h: New file.
        * sysdeps/riscv/e_sqrtl.c: Likewise.
        * sysdeps/riscv/fpu_control.h: Likewise.
        * sysdeps/riscv/math-tests.h: Likewise.
        * sysdeps/riscv/nofpu/Implies: Likewise.
        * sysdeps/riscv/sfp-machine.h: Likewise.
        * sysdeps/riscv/tininess.h: Likewise.

6 years agoRISC-V: Thread-Local Storage Support
Palmer Dabbelt [Mon, 29 Jan 2018 18:25:58 +0000 (10:25 -0800)] 
RISC-V: Thread-Local Storage Support

This patch implements TLS support for RISC-V.  We support all four
standard TLS addressing modes (LE, IE, LD, and GD) when running on
Linux via NPTL.  There is a draft psABI document that defines our TLS
ABI here

  https://github.com/riscv/riscv-elf-psabi-doc/blob/master/riscv-elf.md#thread-local-storage

2018-01-29  Palmer Dabbelt  <palmer@sifive.com>

        * sysdeps/riscv/dl-tls.h: New file.
        * sysdeps/riscv/libc-tls.c: Likewise.
        * sysdeps/riscv/nptl/tcb-offsets.sym: Likewise.
        * sysdeps/riscv/nptl/tls.h: Likewise.
        * sysdeps/riscv/stackinfo.h: Likewise.

6 years agoRISC-V: ABI Implementation
Palmer Dabbelt [Wed, 27 Dec 2017 04:51:24 +0000 (20:51 -0800)] 
RISC-V: ABI Implementation

This patch contains code that needs to directly know about the RISC-V
ABI, which is specified in a work-in-progress psABI document:

  https://github.com/riscv/riscv-elf-psabi-doc/blob/master/riscv-elf.md

This is meant to contain all the RISC-V code that needs to explicitly
name registers or manage in-memory structure layout.  This does not
contain any of the Linux-specific code.

2018-01-29  Palmer Dabbelt  <palmer@sifive.com>

        * sysdeps/riscv/__longjmp.S: New file.
        * sysdeps/riscv/backtrace.c: Likewise.
        * sysdeps/riscv/bits/endian.h: Likewise.
        * sysdeps/riscv/bits/setjmp.h: Likewise.
        * sysdeps/riscv/bits/wordsize.h: Likewise.
        * sysdeps/riscv/bsd-_setjmp.c: Likewise.
        * sysdeps/riscv/bsd-setjmp.c: Likewise.
        * sysdeps/riscv/dl-trampoline.S: Likewise.
        * sysdeps/riscv/gccframe.h: Likewise.
        * sysdeps/riscv/jmpbuf-offsets.h: Likewise.
        * sysdeps/riscv/jmpbuf-unwind.h: Likewise.
        * sysdeps/riscv/machine-gmon.h: Likewise.
        * sysdeps/riscv/memusage.h: Likewise.
        * sysdeps/riscv/setjmp.S: Likewise.
        * sysdeps/riscv/sys/asm.h: Likewise.
        * sysdeps/riscv/tls-macros.h: Likewise.

6 years agoAdd documentation for __riscv_flush_icache
Palmer Dabbelt [Mon, 29 Jan 2018 18:25:23 +0000 (10:25 -0800)] 
Add documentation for __riscv_flush_icache

This function is used by GCC to enforce ordering between data writes and
instruction fetches, and while we'd prefer that users rely on the GCC
intrinsic when possible this is user visible in case that's not
possible.

2018-01-29  Palmer Dabbelt  <palmer@sifive.com>

        * manual/platform.texi: Add RISC-V documenation for
        __riscv_flush_icache.

6 years agoAdd RISC-V entries to config.h.in
Palmer Dabbelt [Mon, 29 Jan 2018 16:59:03 +0000 (08:59 -0800)] 
Add RISC-V entries to config.h.in

These were autogenerated.

2018-01-29  Palmer Dabbelt  <palmer@sifive.com>

        * config.h.in: Regenerate.

6 years agoSkeleton documentation for the RISC-V port
Palmer Dabbelt [Wed, 27 Dec 2017 04:55:44 +0000 (20:55 -0800)] 
Skeleton documentation for the RISC-V port

During the upstreaming process it was suggested that I add a handful of
small documentation entries about the RISC-V port, which I've collected
here.

2018-01-29  Palmer Dabbelt  <palmer@sifive.com>

        * manual/math.texi: RISC-V supports _Float128 and _Float64x.

6 years agosysdeps/init_array: Add PREINIT_FUNCTION to crti.S
Palmer Dabbelt [Thu, 25 Jan 2018 18:33:18 +0000 (10:33 -0800)] 
sysdeps/init_array: Add PREINIT_FUNCTION to crti.S

The RISC-V port contains a crti.S that simply contains a link to
PREINIT_FUNCTION (when defined).  As this should be entirely generic,
Joseph Myers suggested that we update the generic init_array version to
contain this.  Since RISC-V is the only user of init_array this won't
break any existing ports.

2018-01-29  Palmer Dabbelt  <palmer@sifive.com>

        * sysdeps/init_array/crti.S (.section .init_array): Add
        PREINIT_FUNCTION when defined.

6 years agolibnsl: Turn remaining symbols into compat symbols [BZ #22701]
Florian Weimer [Mon, 29 Jan 2018 16:00:14 +0000 (17:00 +0100)] 
libnsl: Turn remaining symbols into compat symbols [BZ #22701]

6 years agomicroblaze: don't use copy_file_range syscall with kernel headers < 4.10
Romain Naour [Mon, 29 Jan 2018 16:12:08 +0000 (16:12 +0000)] 
microblaze: don't use copy_file_range syscall with kernel headers < 4.10

copy_file_range syscall was added for microblaze in 4.10.

This patch makes the MicroBlaze kernel-features.h undefine
__ASSUME_COPY_FILE_RANGE for toolchains built with kernel headers < 4.10.

* sysdeps/unix/sysv/linux/microblaze/kernel-features.h
(__ASSUME_COPY_FILE_RANGE) [__LINUX_KERNEL_VERSION < 0x040A00]: Undef.

[1] https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git/commit/?id=7181e5590e5ba898804aef3ee6be7f27606e6f8b

Signed-off-by: Romain Naour <romain.naour@gmail.com>
6 years agoMake build-many-glibcs.py clean git source directories.
Joseph Myers [Mon, 29 Jan 2018 13:59:33 +0000 (13:59 +0000)] 
Make build-many-glibcs.py clean git source directories.

With the git checkouts of Hurd components in build-many-glibcs.py
involving running autoreconf, there's a risk that generated files
could be left behind by an old autoreconf run (if an old version of
the sources generates those files in the source directory but a new
version does not).

This patch avoids that by using git clean -dxfq when updating git
checkouts.  In this patch, that's conditional on --replace-sources, to
avoid removing any local not-checked-in files someone may have in
their checkout unless the option has been specifically passed that
says it's OK to blow old checkouts away, complete with any local
changes to them.

* scripts/build-many-glibcs.py (Context.git_checkout): Use git
clean -dxfq for git updates when replacing sources.

6 years agoClean up build-many-glibcs.py libcilkrts disabling.
Joseph Myers [Mon, 29 Jan 2018 13:49:21 +0000 (13:49 +0000)] 
Clean up build-many-glibcs.py libcilkrts disabling.

The disabling of libcilkrts in build-many-glibcs.py has some
peculiarities.  It's only for the final GCC build, not the initial
bootstrap one, whereas normally anything disabled for the final build
should be disabled for the bootstrap one as well.  And it's only for
Hurd, when it's more natural by analogy with the libsanitizer
disabling to disable this library unconditionally, not only for
targets where it's known to break.  This patch cleans up that
disabling accordingly, adding a comment so it's obvious it can be
removed once GCC 7 is too old to build glibc.

* scripts/build-many-glibcs.py (Config.build_gcc): Use
--disable-libcilkrts unconditionally, not just for the final GCC
build for Hurd.

6 years agoUse Linux 4.15 in build-many-glibcs.py.
Joseph Myers [Mon, 29 Jan 2018 13:38:21 +0000 (13:38 +0000)] 
Use Linux 4.15 in build-many-glibcs.py.

This patch makes build-many-glibcs.py use Linux 4.15.  Other glibc
updates for Linux 4.15 can wait until after the 2.27 release.

* scripts/build-many-glibcs.py (Context.checkout): Default Linux
version to 4.15.

6 years agolt_LT: Add alternative month names (bug 10871).
Rafal Luzynski [Mon, 29 Jan 2018 12:00:43 +0000 (13:00 +0100)] 
lt_LT: Add alternative month names (bug 10871).

[BZ #10871]
* localedata/locales/lt_LT (alt_mon): Import from CLDR (nominative
case).

6 years agobe_BY, be_BY@latin: Add alternative month names (bug 10871).
Rafal Luzynski [Sun, 28 Jan 2018 00:23:45 +0000 (01:23 +0100)] 
be_BY, be_BY@latin: Add alternative month names (bug 10871).

This patch also fixes spelling of lang_name in be_BY@latin, as reported
by Ihar Hrachyshka.

[BZ #10871]
* localedata/locales/be_BY (mon): Rename to...
(alt_mon): This, then synchronize with CLDR (nominative case).
(abmon): Rename to...
(ab_alt_mon): This, then synchronize with CLDR (nominative case).
(mon): Import from CLDR (genitive case).
(abmon): Likewise.
* localedata/locales/be_BY@latin (mon): Rename to...
(alt_mon): This.
(mon): Add, proper genitive forms provided by Viktar Siarheichyk.

* localedata/locales/be_BY@latin (lang_name): Reworded to
"bieÅ‚aruskaja mova".

6 years agoel_CY, el_GR: Add alternative month names (bug 10871).
Rafal Luzynski [Sat, 27 Jan 2018 00:33:38 +0000 (01:33 +0100)] 
el_CY, el_GR: Add alternative month names (bug 10871).

[BZ #10871]
* localedata/locales/el_CY (mon): Renamed to...
(alt_mon): This.
(mon): Import from CLDR (genitive case).
* localedata/locales/el_GR: Likewise.

6 years agoru_RU, ru_UA: Add alternative month names (bug 10871).
Rafal Luzynski [Tue, 5 Jan 2016 02:04:41 +0000 (03:04 +0100)] 
ru_RU, ru_UA: Add alternative month names (bug 10871).

[BZ #10871]
* localedata/locales/ru_RU (mon): Rename to...
(alt_mon): This.
(abmon): Rename to...
(ab_alt_mon): This.
(mon): Import from CLDR (genitive case).
(abmon): Copy from the old content except the 5th month which is
now in the genitive case, even when abbreviated.
* localedata/locales/ru_UA: Likewise.
* time/tst-strptime.c (day_tests): Add an actual example of
a difference between %b and %Ob in Russian.

6 years agohurd: Fix includes
Samuel Thibault [Mon, 29 Jan 2018 00:48:24 +0000 (01:48 +0100)] 
hurd: Fix includes

* sysdeps/mach/hurd/net/ethernet.h: Include <stdint.h>.
* sysdeps/mach/hurd/net/if_arp.h: Include <stdint.h>.
* sysdeps/mach/hurd/net/if_ppp.h: Do not include non-existing
<net/ppp_defs.h>.

6 years agohurd: Fix _POSIX_VDISABLE value
Samuel Thibault [Sun, 28 Jan 2018 23:05:20 +0000 (00:05 +0100)] 
hurd: Fix _POSIX_VDISABLE value

* sysdeps/mach/hurd/bits/posix_opt.h (_POSIX_VDISABLE): Set to '\0'
instead of invalid -1.

6 years agohurd: Build stubs for new gnumach.defs
Samuel Thibault [Sun, 28 Jan 2018 18:38:09 +0000 (19:38 +0100)] 
hurd: Build stubs for new gnumach.defs

* mach/Makefile (user-interfaces): Add mach/gnumach.
* sysdeps/mach/configure.ac (mach_interface_list): Add gnumach.
* sysdeps/mach/configure (mach_interface_list): Regenerate.

6 years agohurd: Include <sigsetops.h> from hurd/hurd/signal.h
Samuel Thibault [Sun, 28 Jan 2018 18:36:29 +0000 (19:36 +0100)] 
hurd: Include <sigsetops.h> from hurd/hurd/signal.h

* hurd/hurd/signal.h [__USE_EXTERN_INLINES][_LIBC][IS_IN(libc) ||
IS_IN(libpthread)]: Include <sigsetops.h>.

6 years agohurd: Fix allocalim build
Samuel Thibault [Sun, 28 Jan 2018 18:33:37 +0000 (19:33 +0100)] 
hurd: Fix allocalim build

* sysdeps/pthread/allocalim.h [!defined PTHREAD_STACK_MIN]: Do not
check size against PTHREAD_STACK_MIN.

6 years agohurd: fix typo
Samuel Thibault [Sun, 28 Jan 2018 18:27:19 +0000 (19:27 +0100)] 
hurd: fix typo

6 years agohurd: Fix posix options
Samuel Thibault [Sun, 28 Jan 2018 18:13:55 +0000 (19:13 +0100)] 
hurd: Fix posix options

_POSIX_CHOWN_RESTRICTED and _POSIX_NO_TRUNC should be always defined.

* sysdeps/mach/hurd/bits/posix_opt.h (_POSIX_CHOWN_RESTRICTED,
_POSIX_NO_TRUNC): Define to 0.

6 years agoRevert "hurd: Fix building io/tst-fchownat.c"
Samuel Thibault [Sun, 28 Jan 2018 18:13:20 +0000 (19:13 +0100)] 
Revert "hurd: Fix building io/tst-fchownat.c"

This reverts commit fc221145a734d128d8f56f40d40fd4bb70a1d151.

6 years agohurd: Fix getifaddrs / freeifaddrs exposition
Samuel Thibault [Sun, 28 Jan 2018 18:06:15 +0000 (19:06 +0100)] 
hurd: Fix getifaddrs / freeifaddrs exposition

400669754de4 ('hurd: Fix nscd build') had the side effect of making
libc's freeaddrinfo expose freeifaddrs through __check_pf.  We can just
move the renames to gai.c itself, along others.

* sysdeps/mach/hurd/check_pf.c (__getifaddrs, __freeifaddrs): Do not
define macros.
* nscd/gai.c (__getifaddrs): Define macro to getifaddrs.
(__freeifaddrs): Define macro to freeifaddrs.

6 years agohurd: take __USE_EXTERN_INLINES into account and restrict inlines
Samuel Thibault [Sun, 28 Jan 2018 17:43:10 +0000 (18:43 +0100)] 
hurd: take __USE_EXTERN_INLINES into account and restrict inlines

* hurd/hurd.h (__hurd_fail): Always declare function, and provide inline
version only if __USE_EXTERN_INLINES is defined.
* hurd/hurd/fd.h (_hurd_fd_error_signal, _hurd_fd_error, __hurd_dfail,
__hurd_sockfail): Likewise.
(_hurd_fd_get): Always declare functions, and provide inline versions
only if __USE_EXTERN_INLINES and _LIBC are defined and IS_IN(libc).
* hurd/hurd/port.h (_hurd_port_init, _hurd_port_locked_get,
_hurd_port_get, _hurd_port_free, _hurd_port_locked_set,
_hurd_port_set): Always declare functions, and provide inline versions
only if __USE_EXTERN_INLINES and _LIBC are defined and
IS_IN(libc).
* hurd/hurd/signal.h (_hurd_self_sigstate, _hurd_critical_section_lock,
_hurd_critical_section_unlock): Likewise.
* hurd/hurd/threadvar.h (__hurd_threadvar_location_from_sp,
* __hurd_threadvar_location): Likewise.
* hurd/hurd/userlink.h (_hurd_userlink_link, _hurd_userlink_unlink,
_hurd_userlink_clear): Likewise.
* mach/lock-intern.h (__spin_lock_init, __spin_lock, __mutex_lock,
__mutex_unlock, __mutex_trylock): Always declare functions, and provide
inline versions only if __USE_EXTERN_INLINES and _LIBC are defined.
* mach/mach/mig_support.h (__mig_strncpy): Likewise.
* sysdeps/generic/machine-lock.h (__spin_unlock, __spin_try_lock,
__spin_lock_locked): Likewise.
* sysdeps/mach/i386/machine-lock.h (__spin_unlock, __spin_try_lock,
__spin_lock_locked): Likewise.
* mach/spin-lock.c (__USE_EXTERN_INLINES): Define to 1.
* hurd/Versions (libc: GLIBC_2.27): Add _hurd_fd_error_signal,
_hurd_fd_error, __hurd_dfail, __hurd_sockfail, _hurd_port_locked_set,
__hurd_threadvar_location_from_sp, __hurd_threadvar_location,
_hurd_userlink_link, _hurd_userlink_unlink, _hurd_userlink_clear.

6 years agohurd: Fix building io/tst-copy_file_range.c
Samuel Thibault [Sun, 28 Jan 2018 16:56:49 +0000 (17:56 +0100)] 
hurd: Fix building io/tst-copy_file_range.c

* io/tst-copy_file_range.c [!defined CLONE_NEWNS]: Do not include
<sys/mount.h>.

6 years agohurd: Fix building io/tst-fchownat.c
Samuel Thibault [Sun, 28 Jan 2018 16:52:34 +0000 (17:52 +0100)] 
hurd: Fix building io/tst-fchownat.c

* io/tst-fchownat.c [!defined _POSIX_CHOWN_RESTRICTED]: Act like when
_POSIX_CHOWN_RESTRICTED is defined to 0.

6 years agohurd: Fix building libio/tst-memstream3.c
Samuel Thibault [Sun, 28 Jan 2018 16:45:41 +0000 (17:45 +0100)] 
hurd: Fix building libio/tst-memstream3.c

FWRITE is already an fcntl.h macro.

* libio/tst-memstream3.c (FWRITE): Rename to _FWRITE.
(do_test_bz20181): Rename accordingly.
* libio/tst-wmemstream3.c (FWRITE): Rename accordingly.

6 years agohurd: add base abilist files
Samuel Thibault [Sun, 28 Jan 2018 16:26:35 +0000 (17:26 +0100)] 
hurd: add base abilist files

* sysdeps/mach/hurd/libhurduser.abilist: New file.
* sysdeps/mach/libmachuser.abilist: New file.

6 years agohurd: Add missing fcntl-internal.h
Thomas Schwinge [Sun, 28 Jan 2018 15:53:32 +0000 (16:53 +0100)] 
hurd: Add missing fcntl-internal.h

* hurd/fcntl-internal.h: New file.

6 years agohurd: Fix nscd build
Samuel Thibault [Sun, 28 Jan 2018 15:28:48 +0000 (16:28 +0100)] 
hurd: Fix nscd build

nscd won't find check_* from inet/, it needs a sysdeps file.

* sysdeps/mach/hurd/check_native.c: New file.
* sysdeps/mach/hurd/check_pf.c: New file.

6 years agohurd: Fix warnings
Samuel Thibault [Sun, 28 Jan 2018 15:23:59 +0000 (16:23 +0100)] 
hurd: Fix warnings

* hurd/hurd/lookup.h (__hurd_file_name_lookup, hurd_file_name_lookup,
__hurd_file_name_split, hurd_file_name_split,
__hurd_directory_name_split, hurd_directory_name_split,
__hurd_file_name_lookup_retry, hurd_file_name_lookup_retry,
hurd_file_name_path_lookup): Make lookup function parameter take a
const char *name instead of char *name.
* hurd/hurdlookup.c (__hurd_file_name_lookup, __hurd_file_name_split,
__hurd_directory_name_split): Likewise.
* hurd/lookup-retry.c (__hurd_file_name_lookup_retry): Likewise.
* hurd/path-lookup.c (hurd_file_name_path_lookup): Likewise.

6 years agohurd: Fix warning
Samuel Thibault [Sun, 28 Jan 2018 15:21:28 +0000 (16:21 +0100)] 
hurd: Fix warning

* sysdeps/mach/hurd/spawni.c (__spawni): Make relpath and abspath
const char * instead of char *.

6 years agohurd: Make build-many-glibcs.py use mainline gnumach
Samuel Thibault [Sun, 28 Jan 2018 14:48:04 +0000 (15:48 +0100)] 
hurd: Make build-many-glibcs.py use mainline gnumach

Some warnings need a couple of fixes in the gnumach headers.

        * scripts/build-many-glibcs.py (checkout_vcs): Add gnumach
        repository URLs, run autoreconf, and make it the default for now.

6 years agohurd: fix warning
Samuel Thibault [Sat, 27 Jan 2018 22:49:18 +0000 (23:49 +0100)] 
hurd: fix warning

* sysdeps/mach/hurd/getresgid.c (__getresgid): Set result from
critical section to make code simpler and avoid warning.
* sysdeps/mach/hurd/getresuid.c (__getresuid): Set result from
critical section to make code simpler and avoid warning.

6 years agohurd: Fix enabling vm_copy
Samuel Thibault [Sat, 27 Jan 2018 21:09:30 +0000 (22:09 +0100)] 
hurd: Fix enabling vm_copy

Benchmarked on
http://lists.gnu.org/archive/html/bug-hurd/2014-12/msg00081.html

* sysdeps/mach/pagecopy.h (PAGE_THRESHOLD): Rename to
PAGE_COPY_THRESHOLD and set to benchmarked 16384.

6 years agohurd: fix warning
Samuel Thibault [Sat, 27 Jan 2018 21:01:34 +0000 (22:01 +0100)] 
hurd: fix warning

Making `special_profil_failure' both avoids warning "variable
'special_profil_failure' set but not used", and makes it easier to
access with gdb.

* sysdeps/mach/hurd/profil.c (special_profil_failure): Move variable
to global scope.

6 years agohurd: fix warning
Samuel Thibault [Sat, 27 Jan 2018 21:00:23 +0000 (22:00 +0100)] 
hurd: fix warning

* sysdeps/mach/hurd/dl-sysdep.c (_exit): Call LOSE and abort() if
__task_terminate would ever return successfully.

6 years agohurd: make build-many-glibcs.py use mainline mig
Samuel Thibault [Sat, 27 Jan 2018 20:44:57 +0000 (21:44 +0100)] 
hurd: make build-many-glibcs.py use mainline mig

Some warnings come from code generated by mig, so we need a very recent
version for now.

        * scripts/build-many-glibcs.py (checkout_vcs): Add mig repository
        URL, and run autoreconf, make it the default for now.

6 years agohurd: drop elder MACH_IPC_COMPAT handling
Samuel Thibault [Sat, 27 Jan 2018 20:40:08 +0000 (21:40 +0100)] 
hurd: drop elder MACH_IPC_COMPAT handling

This was dropped from GNU Mach in 2006.

* mach/Machrules (MIGFLAGS): Do not set -DMACH_IPC_COMPAT=0.
* mach/mach/mach_traps.h: Drop comment about MACH_IPC_COMPAT.
* sysdeps/mach/hurd/fork.c (__fork): Drop special casing
MACH_IPC_COMPAT.

6 years agohurd: fix warning
Samuel Thibault [Sat, 27 Jan 2018 20:37:29 +0000 (21:37 +0100)] 
hurd: fix warning

* sysdeps/mach/hurd/Makefile [$(subdir)==nis]: Add
-DUSE_BINDINGDIR=1 to CFLAGS-ypclnt.c.

6 years agohurd: fix gcc build in build-many-glibcs.py
Samuel Thibault [Sat, 27 Jan 2018 18:53:44 +0000 (19:53 +0100)] 
hurd: fix gcc build in build-many-glibcs.py

gcc's libcilkrts has never actually supported GNU/Hurd, and doesn't
automatically disable it, and the support was actually removed in gcc trunk,
so that will never actually be fixed there.

* scripts/build-many-glibcs.py [os == gnu] (build_gcc): Pass
--disable-libcilkrts to gcc configure.

6 years agohurd: fix warning
Samuel Thibault [Sat, 27 Jan 2018 16:17:49 +0000 (17:17 +0100)] 
hurd: fix warning

timer_ptr2id and timer_id2ptr are used to convert between
application-visible timer_t and struct timer_node *. timer_ptr2id was made
to use void * instead of timer_t in 49b650430eb5 ('Update.') for no reason.
It happens that on Linux timer_t is void *, so both that change and this
commit are no-ops there, but not on systems where timer_t is not void *.

Using timer_ptr2id for filling sival_ptr also does not make sense since that
actually is a void *.

* sysdeps/pthread/posix-timer.h (timer_ptr2id): Cast to timer_t
instead of void *.
* sysdeps/pthread/timer_create.c (timer_create): Do not use
timer_ptr2id to cast struct timer_node * to void *.

6 years agohurd: fix warning
Samuel Thibault [Sat, 27 Jan 2018 15:49:05 +0000 (16:49 +0100)] 
hurd: fix warning

* sysdeps/mach/hurd/dl-sysdep.c (_dl_sysdep_start): Cast
vm_address_t * to ElfW(Addr) * for dl_main parameter.

6 years agohurd: fix warnings
Samuel Thibault [Sat, 27 Jan 2018 15:47:36 +0000 (16:47 +0100)] 
hurd: fix warnings

* sysdeps/generic/sigsetops.h (__sigemptyset, __sigfillset,
__sigandset, __sigorset, __sigaddset, __sigdelset): Make them really
return 0.

6 years agohurd: fix warning
Samuel Thibault [Sat, 27 Jan 2018 15:45:55 +0000 (16:45 +0100)] 
hurd: fix warning

* sysdeps/generic/sigset-cvt-mask.h: Include <sigsetops.h>.

6 years agohurd: fix warnings
Samuel Thibault [Sat, 27 Jan 2018 15:45:10 +0000 (16:45 +0100)] 
hurd: fix warnings

* sysdeps/generic/not-cancel.h: Include <fcntl.h>, <unistd.h>,
<sys/wait.h>, <time.h>, <sys/uio.h>.
(NOT_CANCEL_H): Add inclusion guard.

6 years agohurd: fix warning
Samuel Thibault [Sat, 27 Jan 2018 15:42:58 +0000 (16:42 +0100)] 
hurd: fix warning

* resolv/res-close.c: Include <stdlib.h>.

6 years agohurd: fix warning
Samuel Thibault [Sat, 27 Jan 2018 15:33:13 +0000 (16:33 +0100)] 
hurd: fix warning

* sysdeps/mach/hurd/profil.c: Reuse `a' variable instead of introducing
a `c' variable.

6 years agohurd: fix warning
Samuel Thibault [Sat, 27 Jan 2018 15:32:16 +0000 (16:32 +0100)] 
hurd: fix warning

* sysdeps/mach/hurd/xmknodat.c: Include <sys/sysmacros.h>.

6 years agoUpdate hppa libm-test-ulps
James Clarke [Sat, 27 Jan 2018 01:52:54 +0000 (01:52 +0000)] 
Update hppa libm-test-ulps

* sysdeps/hppa/fpu/libm-test-ulps: Update.

Signed-off-by: James Clarke <jrtc27@jrtc27.com>
6 years agoUpdate Alpha libm-test-ulps
James Clarke [Sat, 27 Jan 2018 01:17:45 +0000 (01:17 +0000)] 
Update Alpha libm-test-ulps

* sysdeps/alpha/fpu/libm-test-ulps: Update.

Signed-off-by: James Clarke <jrtc27@jrtc27.com>
6 years agoAdd ChangeLog entry for "pl_PL: Add alternative month names".
Rafal Luzynski [Sat, 27 Jan 2018 01:03:34 +0000 (02:03 +0100)] 
Add ChangeLog entry for "pl_PL: Add alternative month names".

6 years agoBuild only shared libnsl objects if NIS is disabled (bug 22701)
Andreas Schwab [Fri, 26 Jan 2018 18:01:03 +0000 (19:01 +0100)] 
Build only shared libnsl objects if NIS is disabled (bug 22701)

6 years agoREADME: hppa no longer requires patches.
Carlos O'Donell [Fri, 26 Jan 2018 17:49:54 +0000 (09:49 -0800)] 
README: hppa no longer requires patches.

6 years agoUpdate sparc ULPs.
Patrick McGehearty [Fri, 26 Jan 2018 16:23:01 +0000 (08:23 -0800)] 
Update sparc ULPs.

        * sysdeps/sparc/fpu/libm-test-ulps: Update
        cpow, ctan, ctanh, j0, j1, y0, yn ulps.

6 years agoRevert Intel CET changes to __jmp_buf_tag (Bug 22743)
Carlos O'Donell [Thu, 25 Jan 2018 04:35:22 +0000 (20:35 -0800)] 
Revert Intel CET changes to __jmp_buf_tag (Bug 22743)

In commit cba595c350e52194e10c0006732e1991e3d0803b and commit
f81ddabffd76ac9dd600b02adbf3e1dac4bb10ec, ABI compatibility with
applications was broken by increasing the size of the on-stack
allocated __pthread_unwind_buf_t beyond the oringal size.
Applications only have the origianl space available for
__pthread_unwind_register, and __pthread_unwind_next to use,
any increase in the size of __pthread_unwind_buf_t causes these
functions to write beyond the original structure into other
on-stack variables leading to segmentation faults in common
applications like vlc. The only workaround is to version those
functions which operate on the old sized objects, but this must
happen in glibc 2.28.

Thank you to Andrew Senkevich, H.J. Lu, and Aurelien Jarno, for
submitting reports and tracking the issue down.

The commit reverts the above mentioned commits and testing on
x86_64 shows that the ABI compatibility is restored. A tst-cleanup1
regression test linked with an older glibc now passes when run
with the newly built glibc. Previously a tst-cleanup1 linked with
an older glibc would segfault when run with an affected glibc build.

Tested on x86_64 with no regressions.

Signed-off-by: Carlos O'Donell <carlos@redhat.com>
6 years agohurd build-many-glibcs.py: use hurd mainline for now
Samuel Thibault [Fri, 26 Jan 2018 01:35:10 +0000 (02:35 +0100)] 
hurd build-many-glibcs.py: use hurd mainline for now

* scripts/build-many-glibcs.py (checkout_vcs): Make hurd
mainline the default for now.

6 years agoAdd ChangeLog entry for "uk_UA: Add alternative month names".
Rafal Luzynski [Thu, 25 Jan 2018 23:21:16 +0000 (00:21 +0100)] 
Add ChangeLog entry for "uk_UA: Add alternative month names".

6 years agoAdd support for the RISC-V-specific ELF flags
Palmer Dabbelt [Sat, 13 Jan 2018 09:59:12 +0000 (01:59 -0800)] 
Add support for the RISC-V-specific ELF flags

The RISC-V port defines ELF flags that enforce compatibility between
various objects.  This adds the shared support necessary for these
flags.

2018-01-25  Palmer Dabbelt  <palmer@sifive.com>

        * elf/cache.c (print_entry): Add FLAG_RISCV_FLOAT_ABI_SOFT and
        FLAG_RISCV_FLOAT_ABI_DOUBLE.
        * elf/elf.h (EF_RISCV_RVC): New define.
        (EF_RISCV_FLOAT_ABI): Likewise.
        (EF_RISCV_FLOAT_ABI_SOFT): Likewise.
        (EF_RISCV_FLOAT_ABI_SINGLE): Likewise.
        (EF_RISCV_FLOAT_ABI_DOUBLE): Likewise.
        (EF_RISCV_FLOAT_ABI_QUAD): Likewise.
        * sysdeps/generic/ldconfig.h (FLAG_RISCV_FLOAT_ABI_SOFT): New
        define.
        (FLAG_RISCV_FLOAT_ABI_DOUBLE): Likewise.

6 years agoLIBC_SLIBDIR_RTLDDIR: substitute arguments in single quotes
Andreas Schwab [Thu, 25 Jan 2018 09:41:27 +0000 (10:41 +0100)] 
LIBC_SLIBDIR_RTLDDIR: substitute arguments in single quotes

The arguments of the LIBC_SLIBDIR_RTLDDIR macro are used both in unquoted
and single quoted context, so that neither shell nor makefile variable
references work.  Consistently put them in single quotes so that they can
refer to makefile variables.

6 years agouk_UA: Add alternative month names (bug 10871).
Rafal Luzynski [Tue, 5 Jan 2016 02:06:25 +0000 (03:06 +0100)] 
uk_UA: Add alternative month names (bug 10871).

Primary month names are in a genitive case now, alternative month names
are in a nominative case.

The alternative digits hack is no longer needed and has been removed.

[BZ #10871]
* localedata/locales/uk_UA (mon): Renamed to...
(alt_mon): This.
(alt_digits): "0" removed and then renamed to...
(mon): This.
(date_fmt): Definition changed not to use the alternative
digits hack.

6 years agobuild-many-glibcs.py: Fix hurd-vcs checkout
Samuel Thibault [Thu, 25 Jan 2018 02:14:22 +0000 (03:14 +0100)] 
build-many-glibcs.py: Fix hurd-vcs checkout

* scripts/build-many-glibcs.py (checkout_vcs): Run autoconf.

6 years agobuild-many-glibcs.py: Add hurd vcs support
Samuel Thibault [Thu, 25 Jan 2018 02:01:59 +0000 (03:01 +0100)] 
build-many-glibcs.py: Add hurd vcs support

* scripts/build-many-glibcs.py (checkout_vcs): Add hurd repository URL.

6 years agoAdd soft-float ColdFire to build-many-glibcs.py.
Joseph Myers [Wed, 24 Jan 2018 23:48:52 +0000 (23:48 +0000)] 
Add soft-float ColdFire to build-many-glibcs.py.

Since it turns out soft-float ColdFire has a different glibc ABI to
hard-float ColdFire, as well as various differences in which glibc
code gets built, this patch adds such a configuration to
build-many-glibcs.py to (hopefully) complete the set of ABIs being
tested.  (Note that the build for soft-float ColdFire is currently
broken even with GCC mainline - I have a glibc patch to fix this, but
it needs before-and-after build-many-glibcs.py comparison of stripped
binaries for all configurations before being committed.)

* scripts/build-many-glibcs.py (Context.add_all_configs): Add
soft-float ColdFire configuration.