aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2016-10-06Manual typos: Contributors toRical Jasan
2016-05-06 Rical Jasan <ricaljasan@pacific.net> * manual/contrib.texi: Fix typos in the manual.
2016-10-06Manual typos: Library MaintenanceRical Jasan
2016-05-06 Rical Jasan <ricaljasan@pacific.net> * manual/maint.texi: Fix typos in the manual.
2016-10-06Manual typos: InstallingRical Jasan
2016-05-06 Rical Jasan <ricaljasan@pacific.net> * manual/install.texi: Fix typos in the manual. * INSTALL: Regenerated.
2016-10-06Manual typos: C Language Facilities in the LibraryRical Jasan
2016-05-06 Rical Jasan <ricaljasan@pacific.net> * manual/lang.texi: Fix typos in the manual.
2016-10-06Manual typos: Internal probesRical Jasan
2016-05-06 Rical Jasan <ricaljasan@pacific.net> * manual/probes.texi: Fix typos in the manual.
2016-10-06Manual typos: POSIX ThreadsRical Jasan
2016-05-06 Rical Jasan <ricaljasan@pacific.net> * manual/threads.texi: Fix typos in the manual.
2016-10-06Manual typos: Debugging supportRical Jasan
2016-05-06 Rical Jasan <ricaljasan@pacific.net> * manual/debug.texi: Fix typos in the manual.
2016-10-06Manual typos: DES Encryption and Password HandlingRical Jasan
2016-05-06 Rical Jasan <ricaljasan@pacific.net> * manual/crypt.texi: Fix typos in the manual.
2016-10-06Manual typos: System Configuration ParametersRical Jasan
2016-05-06 Rical Jasan <ricaljasan@pacific.net> * manual/conf.texi: Fix typos in the manual.
2016-10-06Manual typos: System ManagementRical Jasan
2016-05-06 Rical Jasan <ricaljasan@pacific.net> * manual/sysinfo.texi: Fix typos in the manual.
2016-10-06Manual typos: Users and GroupsRical Jasan
2016-05-06 Rical Jasan <ricaljasan@pacific.net> * manual/users.texi: Fix typos in the manual.
2016-10-06Manual typos: Job ControlRical Jasan
2016-05-06 Rical Jasan <ricaljasan@pacific.net> * manual/job.texi: Fix typos in the manual.
2016-10-06Manual typos: ProcessesRical Jasan
2016-05-06 Rical Jasan <ricaljasan@pacific.net> * manual/process.texi: Fix typos in the manual.
2016-10-06Manual typos: The Basic Program/System InterfaceRical Jasan
2016-05-06 Rical Jasan <ricaljasan@pacific.net> * manual/argp.texi: Fix typos in the manual. * manual/getopt.texi: Likewise. * manual/startup.texi: Likewise.
2016-10-06Manual typos: Signal HandlingRical Jasan
2016-05-06 Rical Jasan <ricaljasan@pacific.net> * manual/signal.texi: Fix typos in the manual.
2016-10-06Manual typos: Non-Local ExitsRical Jasan
2016-05-06 Rical Jasan <ricaljasan@pacific.net> * manual/setjmp.texi: Fix typos in the manual.
2016-10-06Manual typos: Resource Usage and LimitationRical Jasan
2016-05-06 Rical Jasan <ricaljasan@pacific.net> * manual/resource.texi: Fix typos in the manual.
2016-10-06Manual typos: Date and TimeRical Jasan
2016-05-06 Rical Jasan <ricaljasan@pacific.net> * manual/time.texi: Fix typos in the manual.
2016-10-06Manual typos: Arithmetic FunctionsRical Jasan
2016-05-06 Rical Jasan <ricaljasan@pacific.net> * manual/arith.texi: Fix typos in the manual.
2016-10-06Manual typos: MathematicsRical Jasan
2016-05-06 Rical Jasan <ricaljasan@pacific.net> * manual/math.texi: Fix typos in the manual.
2016-10-06Manual typos: SyslogRical Jasan
2016-05-06 Rical Jasan <ricaljasan@pacific.net> * manual/syslog.texi: Fix typos in the manual.
2016-10-06Manual typos: Low-Level Terminal InterfaceRical Jasan
2016-05-06 Rical Jasan <ricaljasan@pacific.net> * manual/terminal.texi: Fix typos in the manual.
2016-10-06Manual typos: SocketsRical Jasan
2016-05-06 Rical Jasan <ricaljasan@pacific.net> * manual/socket.texi: Fix typos in the manual.
2016-10-06Manual typos: File System InterfaceRical Jasan
2016-05-06 Rical Jasan <ricaljasan@pacific.net> * manual/filesys.texi: Fix typos in the manual.
2016-10-06Manual typos: Low-Level Input/OutputRical Jasan
2016-05-06 Rical Jasan <ricaljasan@pacific.net> * manual/llio.texi: Fix typos in the manual.
2016-10-06Manual typos: Input/Output on StreamsRical Jasan
2016-05-06 Rical Jasan <ricaljasan@pacific.net> * manual/stdio.text: Fix typos in the manual.
2016-10-06Check n instead of k1 to decide on sign of sin/cos resultSiddhesh Poyarekar
For k1 in 1 and 3, n can only have values of 0 and 2, so checking k1 & 2 is equivalent to checking n & 2. We prefer the latter so that we don't use k1 for anything other than selecting the quadrant in do_sincos_1, thus dropping it completely. The previous logic was: "Compute sine for the value and based on the new rotated quadrant (k1) negate the value if we're in the fourth quadrant." With this change, the logic now is: "Compute sine for the value and negate it if we were either (1) in the fourth quadrant or (2) we actually wanted the cosine and were in the third quadrant." * sysdeps/ieee754/dbl-64/s_sin.c (do_sincos_1): Check N instead of K1.
2016-10-06Make the quadrant shift K a bool in do_sincos_* functionsSiddhesh Poyarekar
The do_sincos_* functions are helpers to compute sin/cos, where they get cosine by computing sine for the next quadrant. This is decided with the value of K passed to it, which is the amount by which to shift the quadrant. Since we will only need the shift to be 0 or 1, we make K a bool to make that explicit. * sysdeps/ieee754/dbl-64/s_sin.c (do_sincos_1): Rename K to SHIFT_QUADRANT and make it bool. (do_sincos_2): Likewise. (sloww): Likewise. (sloww1): Likewise. (__sin): Adjust calls to do_sincos_1 and do_sincos_2. (__cos): Likewise.
2016-10-05powerpc: Regenerate ULPsTulio Magno Quites Machado Filho
* sysdeps/powerpc/fpu/libm-test-ulps: Regenerated.
2016-10-04Fix LONG_WIDTH, ULONG_WIDTH include ordering issue.Joseph Myers
As described in <https://sourceware.org/ml/libc-alpha/2016-10/msg00047.html>, there is an include ordering issue with the integer width macros in glibc's <limits.h>, where definitions conditional on LONG_MAX do not work as intended because when the headers are installed, this part of glibc's <limits.h> is processed before the part of GCC's <limits.h> that will define LONG_MAX. This patch changes the definitions just to use __WORDSIZE for the expansion of LONG_WIDTH and ULONG_WIDTH rather than making those definitions conditional on LONG_MAX. Tested for x86_64 and x86. * include/limits.h [__GLIBC_USE (IEC_60559_BFP_EXT)] (LONG_WIDTH): Define to __WORDSIZE, not conditional on [LONG_MAX == 0x7fffffffL]. [__GLIBC_USE (IEC_60559_BFP_EXT)] (ULONG_WIDTH): Likewise.
2016-10-04powerpc: Installed-header hygieneTulio Magno Quites Machado Filho
Fix powerpc-specific headers: - Make it compatible to C89 by replace references to inline by __inline__. - Get the definition of sigset_t used by sysdeps/unix/sysv/linux/powerpc/sys/ucontext.h. - Includes missing header file.
2016-10-04S390: Regenerate ULPsStefan Liebler
Regenerated ulps file after recent commit "Use __builtin_fma more in dbl-64 code.". ChangeLog: * sysdeps/s390/fpu/libm-test-ulps: Regenerated.
2016-10-03Add TCP_REPAIR_WINDOW from Linux 4.8.Joseph Myers
Linux 4.8 adds TCP_REPAIR_WINDOW to include/uapi/linux/tcp.h. This patch adds it to sysdeps/gnu/netinet/tcp.h accordingly, along with struct tcp_repair_window as requested in <https://sourceware.org/ml/libc-alpha/2016-10/msg00019.html>. Tested for x86_64 and x86 (testsuite, and that installed shared libraries are unchanged by the patch). * sysdeps/gnu/netinet/tcp.h (TCP_REPAIR_WINDOW): New macro. (struct tcp_repair_window): New type.
2016-10-02Fix tst-memstream3 build failureAdhemerval Zanella
Add string.h to avoid tst-memstream3 build failure in some environments: tst-memstream3.c:32:17: error: implicit declaration of function 'strcmp' [-Werror=implicit-function-declaration] # define STRCMP strcmp ^ tst-memstream3.c:96:7: note: in expansion of macro 'STRCMP' if (STRCMP (buf, W("b")) != 0) Checked on x86_64. * libio/tst-memstream3.c: Include string.h.
2016-09-30libio: Multiple fixes for open_{w}memstram (BZ#18241 and BZ#20181)Adhemerval Zanella
This patches fixes multiples issues on open_{w}memstream reported on both BZ#18241 and BZ#20181: - failed fseek does not set errno. - negative offset in fseek fails even when resulting position is a valid one. - a flush after write if the current write position is not at the end of the stream currupt data. The main fix is on seek operation for memstream (_IO_{w}str_seekoff), where both _IO_read_ptr and _IO_read_end pointer are updated if a write operation has occured (similar to default file operations). Also, to calculate the offset on both read and write pointers, a temporary value is instead of updating the argument supplied value. Negative offset are valid if resulting internal pointer is within the range of _IO_{read,write}_base and _IO_{read,write}_end. Also POSIX states that a null or wide null shall be appended to the current buffer iff a write moves the position to a value larger than the current lenght. Current implementation appends a null or wide null regardless of this condition. This patch fixes it by removing the 'else' condition on _IO_{w}mem_sync. Checked on x86_64. [BZ #18241] [BZ #20181] * libio/Makefile (test): Add tst-memstream3 and tst-wmemstream3. * libio/memstream.c (_IO_mem_sync): Only append a null byte if write position is at the end the buffer. * libio/wmemstream.c (_IO_wmem_sync): Likewise. * libio/strops.c (_IO_str_switch_to_get_mode): New function. (_IO_str_seekoff): Set correct offset from negative displacement and set EINVAL for invalid ones. * libio/wstrops.c (enlarge_userbuf): Use correct function to calculate buffer length. (_IO_wstr_switch_to_get_mode): New function. (_IO_wstr_seekoff): Set correct offset from negative displacement and set EINVAL for invalid ones. * libio/tst-memstream3.c: New file. * libio/tst-wmemstream3.c: Likewise. * manual/examples/memstrm.c: Remove warning when priting size_t.
2016-09-30Use __builtin_fma more in dbl-64 code.Joseph Myers
sysdeps/ieee754/dbl-64/dla.h can use a macro DLA_FMS for more efficient double-width operations when fused multiply-subtract is supported. However, this macro is only defined for x86_64, conditional on architecture-specific __FMA4__. This patch makes the code use __builtin_fma conditional on __FP_FAST_FMA, as used elsewhere in glibc. Tested for x86_64, x86 and powerpc. On powerpc (where this is causing fused operations to be used where they weren't previously) I see an increase from 1ulp to 2ulp in the imaginary part of clog10: testing double (without inline functions) Failure: Test: Imaginary part of: clog10 (0x1.7a858p+0 - 0x6.d940dp-4 i) Result: is: -1.2237865208199886e-01 -0x1.f5435146bb61ap-4 should be: -1.2237865208199888e-01 -0x1.f5435146bb61cp-4 difference: 2.7755575615628914e-17 0x1.0000000000000p-55 ulp : 2.0000 max.ulp : 1.0000 Maximal error of real part of: clog10 is : 3 ulp accepted: 3 ulp Maximal error of imaginary part of: clog10 is : 2 ulp accepted: 1 ulp This is actually resulting from atan2 becoming *more* accurate (atan2 (-0x6.d940dp-4, 0x1.7a858p+0) should ideally be -0x1.208cd6e841554p-2 but was -0x1.208cd6e841555p-2 from a powerpc libm built before this change, and is -0x1.208cd6e841554p-2 from a powerpc libm built after this change). Since these functions are not expected to be correctly rounding by glibc's accuracy goals, neither result is a problem, but this does imply that some of this code, although designed to be correctly rounding, is not in fact correctly rounding (possibly because of GCC creating fused operations where the code does not expect it, something we've only disabled for specific functions where it was found to cause large errors). (Of course as previously discussed I think we should remove the slow cases where an error analysis shows this wouldn't increase the errors much above 0.5ulp; it's only functions such as cratan2 that are expected to be correctly rounding, not atan2.) * sysdeps/ieee754/dbl-64/dla.h [__FP_FAST_FMA] (DLA_FMS): Define macro to use __builtin_fma. * sysdeps/x86_64/fpu/dla.h: Remove file.
2016-09-30Fix ldbl-128ibm iscanonical for -mlong-double-64.Joseph Myers
This patch fixes the ldbl-128ibm version of the iscanonical macro not to use __iscanonicall when long double = double (-mlong-double-64). Tested for powerpc. * sysdeps/ieee754/ldbl-128ibm/bits/iscanonical.h [__NO_LONG_DOUBLE_MATH] (__iscanonicall): Do not declare. [__NO_LONG_DOUBLE_MATH] (iscanonical): Define to evaluate to 1.
2016-09-30Bug 20292 - Simplify and test _dl_addr_inside_objectCarlos O'Donell
The function _dl_addr_inside_object is simplified by removing the conditional 'reladdr - l->l_phdr[n].p_vaddr >= 0' which is always true. The function is refactored into it's own object file and a unit test added to verify the correct behaviour of the function.
2016-09-30Add iscanonical.Joseph Myers
TS 18661-1 adds an iscanonical classification macro to <math.h>. The motivation for this is decimal floating-point, where some values have both canonical and noncanonical encodings. For IEEE binary interchange formats, all encodings are canonical. For x86/m68k ldbl-96, and for ldbl-128ibm, there are encodings that do not represent any valid value of the type; although formally iscanonical does not need to handle trap representations (and so could just always return 1), it seems useful, and in line with the description in the TS of "representations that are extraneous to the floating-point model" as being non-canonical (as well as "redundant representations of some or all of its values"), for it to detect those representations and return 0 for them. This patch adds iscanonical to glibc. It goes in a header <bits/iscanonical.h>, included under appropriate conditions in <math.h>. The default header version just evaluates the argument (converted to its semantic type, though current GCC will probably discard that conversion and any exceptions resulting from it) and returns 1. ldbl-96 and ldbl-128ibm then have versions of the header that call a function __iscanonicall for long double (the sizeof-based tests will of course need updating for float128 support, like other such type-generic macro implementations). The ldbl-96 version of __iscanonicall has appropriate conditionals to reflect the differences in the m68k version of that format (where the high mantissa bit may be either 0 or 1 when the exponent is 0 or 0x7fff). Corresponding tests for those formats are added as well. Other architectures do not have any new functions added because just returning 1 is correct for all their floating-point formats. Tested for x86_64, x86, mips64 (to test the default macro version) and powerpc. * math/math.h [__GLIBC_USE (IEC_60559_BFP_EXT)]: Include <bits/iscanonical.h>. * bits/iscanonical.h: New file. * math/s_iscanonicall.c: Likewise. * math/Versions (__iscanonicall): New libm symbol at version GLIBC_2.25. * math/libm-test.inc (iscanonical_test_data): New array. (iscanonical_test): New function. (main): Call iscanonical_test. * math/Makefile (headers): Add bits/iscanonical.h. (type-ldouble-routines): Add s_iscanonicall. * manual/arith.texi (Floating Point Classes): Document iscanonical. * manual/libm-err-tab.pl: Update comment on interfaces without ulps tabulated. * sysdeps/ieee754/ldbl-128ibm/bits/iscanonical.h: New file. * sysdeps/ieee754/ldbl-128ibm/s_iscanonicall.c: Likewise. * sysdeps/ieee754/ldbl-128ibm/test-iscanonical-ldbl-128ibm.c: Likewise. * sysdeps/ieee754/ldbl-128ibm/Makefile (tests): Add test-iscanonical-ldbl-128ibm. * sysdeps/ieee754/ldbl-96/bits/iscanonical.h: New file. * sysdeps/ieee754/ldbl-96/s_iscanonicall.c: Likewise. * sysdeps/ieee754/ldbl-96/test-iscanonical-ldbl-96.c: Likewise. * sysdeps/ieee754/ldbl-96/Makefile: Likewise. * sysdeps/unix/sysv/linux/i386/libm.abilist: Update. * sysdeps/unix/sysv/linux/ia64/libm.abilist: Likewise. * sysdeps/unix/sysv/linux/m68k/m680x0/libm.abilist: Likewise. * sysdeps/unix/sysv/linux/powerpc/powerpc32/fpu/libm.abilist: Likewise. * sysdeps/unix/sysv/linux/powerpc/powerpc32/nofpu/libm.abilist: Likewise. * sysdeps/unix/sysv/linux/powerpc/powerpc64/libm-le.abilist: Likewise. * sysdeps/unix/sysv/linux/powerpc/powerpc64/libm.abilist: Likewise. * sysdeps/unix/sysv/linux/x86_64/64/libm.abilist: Likewise. * sysdeps/unix/sysv/linux/x86_64/x32/libm.abilist: Likewise.
2016-09-29Remove C++ style comments from string3.hAdhemerval Zanella
The new check-installed-headers rule check now complains with C++ comment from string3.h with: ../string/bits/string3.h:129:1: error: C++ style comments are not allowed in ISO C90 // XXX We have no corresponding builtin yet. Let use old C style comment to make compiler happy in old modes. Tested on x86_64. * string/bits/string3.h: Remove C++ style comments.
2016-09-30Use copysign instead of ternary for some sin/cos input rangesSiddhesh Poyarekar
These are remaining cases where we can deduce and conclude that the sign of the result should be the same as the sign of the input being checked. For example, for sin(x), the sign of the result is the same as the result itself for x < pi. Likewise, for sine values where x after range reduction falls into this range and its sign is preserved. * sysdeps/ieee754/dbl-64/s_sin.c (do_sincos_1): Use copysign instead of ternary condition. (do_sincos_2): Likewise. (__sin): Likewise. (__cos): Likewise. (slow): Likewise. (sloww): Likewise. (sloww1): Likewise. (bsloww): Likewise. (bsloww1): Likewise.
2016-09-30Use copysign instead of ternary conditions for positive constantsSiddhesh Poyarekar
This is the first very simple substitution of ternary conditions for correction adjustments with __copysign for positive constants. * sysdeps/ieee754/dbl-64/s_sin.c (do_cos_slow): use copysign instead of ternary condition. (do_sin_slow): Likewise. (do_sincos_1): Likewise. (do_sincos_2): Likewise. (__cos): Likewise. (sloww): Likewise. (sloww1): Likewise. (sloww2): Likewise. (bsloww): Likewise. (bsloww1): Likewise. (bsloww2): Likewise.
2016-09-30consolidate sign checks for slow2Siddhesh Poyarekar
Simplify the code a bit by consolidating sign checks in slow1 and slow2 into __sin at the higher level. * sysdeps/ieee754/dbl-64/s_sin.c (slow1): Consolidate sign check from here... (slow2): ... and here... (__sin): ... to here.
2016-09-28Fix iszero for excess precision.Joseph Myers
Floating-point classification macros are supposed to remove any excess range or precision from their arguments. This patch fixes the non-sNaN version of iszero to do so, by casting the argument to its own type. (This will of course work only for standard-conforming excess precision, not for what GCC does on 32-bit x86 by default where the back end hides excess precision from the front end; the same applies to most of the classification macros in that case, as showed up when we made them use GCC built-in functions.) (iseqsig will have the reverse issue, needing to ensure that when an underlying function is used it's for a type wide enough not to remove any excess precision, since comparison macros must not remove excess precision.) Tested for x86_64 and x86. * math/math.h [__GLIBC_USE (IEC_60559_BFP_EXT) && !__SUPPORT_SNAN__] (iszero): Cast argument to its own type. * math/test-iszero-excess-precision.c: New file. * math/Makefile (tests): Add test-iszero-excess-precision. (CFLAGS-test-iszero-excess-precision.c): New variable.
2016-09-28posix: Fix open file action for posix_spawn on LinuxAdhemerval Zanella
On posix_spawn open file action (issued by posix_spawn_file_actions_addopen) POSIX states that if fildes was already an open file descriptor, it shall be closed before the new file is openedi [1]. This avoid pontential issues when posix_spawn plus addopen action is called with the process already at maximum number of file descriptor opened and also for multiple actions on single-open special paths (like /dev/watchdog). This fixes its behavior on Linux posix_spawn implementation and also adds a tests to check for its behavior. Checked on x86_64. * posix/Makefile (tests): Add tst-spawn3. * posix/tst-spawn3.c: New file. * sysdeps/unix/sysv/linux/spawni.c (__spawni_child): Close file descriptor if it is already opened for open action. [1] http://pubs.opengroup.org/onlinepubs/9699919799/functions/posix_spawn_file_actions_addclose.html
2016-09-28linux: spawni.c: simplify error reporting to parentRasmus Villemoes
Using CLONE_VFORK already ensures that the parent does not run until the child has either exec'ed succesfully or called _exit. Hence we don't need to read from a CLOEXEC pipe to ensure proper synchronization - we just make explicit use of the fact the the child and parent run in the same VM, so the child can write an error code to a field of the posix_spawn_args struct instead of sending it through a pipe. To ensure that this mechanism really works, the parent initializes the field to -1 and the child writes 0 before execing. This eliminates some annoying bookkeeping that is necessary to avoid the file actions from clobbering the write end of the pipe, and getting rid of the pipe creation in the first place means fewer system calls (four in the parent, usually one in the child) and fewer chanches for the spawn to fail (e.g. if we're close to EMFILE). Checked on x86_64 and i686. * sysdeps/unix/sysv/linux/spawni.c (posix_spawn_args): Remove pipe field, add err field. (__spawni_child): Report error through err member instead of pipe. (__spawnix): Likewise.
2016-09-28Minor corrections to scripts/check-installed-headers.sh.Zack Weinberg
* scripts/check-installed-headers.sh: Generalize treatment of sys/elf.h to all target architectures.
2016-09-28Minor correction to the "installed header hygiene" patches.Zack Weinberg
* sysdeps/unix/sysv/linux/s390/sys/ucontext.h: Restore accidentally- deleted typedef ucontext_t.
2016-09-26Add INTERNAL_SYSCALL_CALLAdhemerval Zanella
This patch adds two new macros for internal and inline syscall to use within GLIBC: INTERNAL_SYSCALL_CALL and INLINE_SYSCALL_CALL. They are similar to the old INTERNAL_SYSCALL and INLINE_SYSCALL with the difference the new macros accept a variable argument call and do not require to pass the expected argument size. The advantage is it is possible to use variable argument macros like SYSCALL_LL{64} without the need to also handle the argument size. So for an ABI where SYSCALL_LL might split the argument in high and low parts, instead of: INTERNAL_SYSCALL_DECL (err); #if ... INTERNAL_SYSCALL (syscall, err, 2, SYSCALL_LL (len)); #else INTERNAL_SYSCALL (syscall, err, 1, SYSCALL_LL (len)); #endif It will be just: INTERNAL_SYSCALL_CALL (syscall, err, SYSCALL_LL (len)); The INLINE_SYSCALL_CALL follows the same semanthic regarding the argument and is similar to INLINE_SYSCALL regarding setting errno. Checked with a build for x86_64, i386, aach64, armhf, powerpc64le, powerpc32, and mips32. No code generation changed. * sysdeps/unix/sysdep.h (__INTERNAL_SYSCALL0): New macro. (__INTERNAL_SYSCALL1): Likewise. (__INTERNAL_SYSCALL2): Likewise. (__INTERNAL_SYSCALL3): Likewise. (__INTERNAL_SYSCALL4): Likewise. (__INTERNAL_SYSCALL5): Likewise. (__INTERNAL_SYSCALL6): Likewise. (__INTERNAL_SYSCALL7): Likewise. (__INTERNAL_SYSCALL_NARGS_X): Likewise. (__INTERNAL_SYSCALL_NARGS): Likewise. (__INTERNAL_SYSCALL_DISP): Likewise. (INTERNAL_SYSCALL_CALL): Likewise. (__SYSCALL0): Rename to __INLINE_SYSCALL0. (__SYSCALL1): Rename to __INLINE_SYSCALL1. (__SYSCALL2): Rename to __INLINE_SYSCALL2. (__SYSCALL3): Rename to __INLINE_SYSCALL3. (__SYSCALL4): Rename to __INLINE_SYSCALL4. (__SYSCALL5): Rename to __INLINE_SYSCALL5. (__SYSCALL6): Rename to __INLINE_SYSCALL6. (__SYSCALL7): Rename to __INLINE_SYSCALL7. (__SYSCALL_NARGS_X): Rename to __INLINE_SYSCALL_NARGS_X. (__SYSCALL_NARGS): Rename to __INLINE_SYSCALL_NARGS. (__SYSCALL_DISP): Rename to __INLINE_SYSCALL_DISP. (__SYSCALL_CALL): Rename to INLINE_SYSCALL_CALL. (SYSCALL_CANCEL): Replace __SYSCALL_CALL with INLINE_SYSCALL_CALL.
2016-09-23Add iszero.Joseph Myers
TS 18661-1 adds an iszero classification macro to <math.h>. This patch implements it for glibc. There are no new underlying functions in libm because the implementation uses fpclassify when sNaN support is required and a direct comparison otherwise; any optimizations for this macro should be done through adding __builtin_iszero in GCC and using it in the header for suitable GCC versions, not through adding other optimized inline or out-of-line versions to glibc. Tested for x86_64 and x86. * math/math.h [__GLIBC_USE (IEC_60559_BFP_EXT)] (iszero): New macro. * math/libm-test.inc (iszero_test_data): New array. (iszero_test): New function. (main): Call iszero_test. * manual/arith.texi (Floating Point Classes): Document iszero. * manual/libm-err-tab.pl: Update comment on interfaces without ulps tabulated.