git: libm: Sync with FreeBSD (~50 math functions added)

John Marino marino at crater.dragonflybsd.org
Wed Dec 21 23:24:09 PST 2011


commit 1a3b704c5cf3ce3034c25a0318f2ceaaf0eea361
Author: John Marino <draco at marino.st>
Date:   Wed Dec 21 18:10:04 2011 +0100

    libm: Sync with FreeBSD (~50 math functions added)
    
    The main purpose of syncing with FreeBSD is to obtain numerous "long double"
    functions which are required for C99 compliance.  There are still many
    functions missing.  According to g++ testsuite, the following 10 functions
    still must be implemented at least:
            coshl           logl            expl
            sinhl           log2l           expm1l
            acoshl          log10l
            asinhl          log1pl
    
    Also known missing are nexttowardl, tgammal, and the long double version of
    most of several complex functions.
    
    A few years ago the freebsd-based math library was thrown out in favor of
    the NetBSD version.  It may be time to reverse that and sync the entire
    libm with FreeBSD.  Right now the DragonFly libm is a mixture between the
    two and it doesn't divide nicely.  All the rounding and rint functions from
    NetBSD had to be thrown out as well as the "kernel" functions.  For the
    short term this is okay, but in the long term it would be a good idea to
    start tracking FreeBSD again.  They are maintaining this library more
    frequently and adding more functions more rapidly than NetBSD, so it would
    be good to piggy-back on that effort.
    
    The man page will be committed separately.

Summary of changes:
 include/complex.h                 |    3 +
 include/math.h                    |   76 +++++--
 lib/libm/arch/i386/Makefile.inc   |    9 +-
 lib/libm/arch/i386/e_remainderl.S |   61 +++++
 lib/libm/arch/i386/e_sqrtl.S      |   50 ++++
 lib/libm/arch/i386/lrint.S        |   26 --
 lib/libm/arch/i386/s_lrint.S      |   44 ++++
 lib/libm/arch/i386/s_lrintf.S     |   44 ++++
 lib/libm/arch/i386/s_lrintl.S     |   47 ++++
 lib/libm/arch/i386/s_remquol.S    |   97 ++++++++
 lib/libm/arch/i386/s_scalbnf.S    |    3 +
 lib/libm/arch/i386/s_scalbnl.S    |    3 +
 lib/libm/complex/Makefile.inc     |   26 ++-
 lib/libm/complex/s_cargl.c        |   37 +++
 lib/libm/complex/s_csqrtl.c       |  109 +++++++++
 lib/libm/complex/w_cabsl.c        |   19 ++
 lib/libm/src/Makefile.inc         |   23 ++-
 lib/libm/src/b_exp.c              |  130 ++++++++++
 lib/libm/src/b_log.c              |  471 +++++++++++++++++++++++++++++++++++++
 lib/libm/src/b_tgamma.c           |  316 +++++++++++++++++++++++++
 lib/libm/src/e_acosl.c            |   84 +++++++
 lib/libm/src/e_asinl.c            |   74 ++++++
 lib/libm/src/e_atan2l.c           |  117 +++++++++
 lib/libm/src/e_fmodl.c            |  148 ++++++++++++
 lib/libm/src/e_hypotl.c           |  123 ++++++++++
 lib/libm/src/e_lgamma_r.c         |   23 +-
 lib/libm/src/e_lgammaf_r.c        |   21 +-
 lib/libm/src/e_log2.c             |   14 +-
 lib/libm/src/e_log2f.c            |    4 +-
 lib/libm/src/e_rem_pio2.c         |  146 ++++++------
 lib/libm/src/e_rem_pio2f.c        |  180 ++++-----------
 lib/libm/src/e_rem_pio2l.h        |  147 ++++++++++++
 lib/libm/src/e_remainderl.c       |   37 +++
 lib/libm/src/e_sqrtl.c            |  160 +++++++++++++
 lib/libm/src/invtrig.c            |   79 ++++++
 lib/libm/src/invtrig.h            |  114 +++++++++
 lib/libm/src/k_cosf.c             |   52 ++---
 lib/libm/src/k_cosl.c             |   76 ++++++
 lib/libm/src/k_rem_pio2.c         |  172 ++++++++++++--
 lib/libm/src/k_sinf.c             |   43 ++--
 lib/libm/src/k_sinl.c             |   60 +++++
 lib/libm/src/k_tanf.c             |  107 +++------
 lib/libm/src/k_tanl.c             |  122 ++++++++++
 lib/libm/src/llrint.c             |   14 -
 lib/libm/src/llrintf.c            |   14 -
 lib/libm/src/llround.c            |   14 -
 lib/libm/src/llroundf.c           |   14 -
 lib/libm/src/lrint.c              |   92 -------
 lib/libm/src/lrintf.c             |   91 -------
 lib/libm/src/lround.c             |   85 -------
 lib/libm/src/lroundf.c            |   80 -------
 lib/libm/src/math_private.h       |   84 ++++++--
 lib/libm/src/mathimpl.h           |   73 ++++++
 lib/libm/src/s_atanl.c            |   82 +++++++
 lib/libm/src/s_cbrtl.c            |  142 +++++++++++
 lib/libm/src/s_ceill.c            |   99 ++++++++
 lib/libm/src/s_copysignl.c        |    2 +-
 lib/libm/src/s_cosf.c             |   64 ++++-
 lib/libm/src/s_cosl.c             |   81 +++++++
 lib/libm/src/s_exp2.c             |    2 +-
 lib/libm/src/s_exp2f.c            |    4 +-
 lib/libm/src/s_exp2l.c            |  293 +++++++++++++++++++++++
 lib/libm/src/s_fabs.c             |   29 +++
 lib/libm/src/s_floorl.c           |   99 ++++++++
 lib/libm/src/s_fma.c              |  283 ++++++++++++++++++++++
 lib/libm/src/s_fmaf.c             |   67 ++++++
 lib/libm/src/s_fmal.c             |  267 +++++++++++++++++++++
 lib/libm/src/s_ldexpf.c           |   29 ---
 lib/libm/src/s_llrint.c           |   10 +
 lib/libm/src/s_llrintf.c          |   10 +
 lib/libm/src/s_llrintl.c          |   10 +
 lib/libm/src/s_llround.c          |   12 +
 lib/libm/src/s_llroundf.c         |   12 +
 lib/libm/src/s_llroundl.c         |   12 +
 lib/libm/src/s_lrint.c            |   58 +++++
 lib/libm/src/s_lrintf.c           |   10 +
 lib/libm/src/s_lrintl.c           |   10 +
 lib/libm/src/s_lround.c           |   66 +++++
 lib/libm/src/s_lroundf.c          |   12 +
 lib/libm/src/s_lroundl.c          |   12 +
 lib/libm/src/s_modf.c             |   77 ++++++
 lib/libm/src/s_modfl.c            |  101 ++++++++
 lib/libm/src/s_nearbyint.c        |    5 +-
 lib/libm/src/s_nexttowardf.c      |   58 +++++
 lib/libm/src/s_remquo.c           |    6 +-
 lib/libm/src/s_remquof.c          |    2 +-
 lib/libm/src/s_remquol.c          |  175 ++++++++++++++
 lib/libm/src/s_rintl.c            |   83 +++++++
 lib/libm/src/s_round.c            |   13 +-
 lib/libm/src/s_roundf.c           |   13 +-
 lib/libm/src/s_roundl.c           |   50 ++++
 lib/libm/src/s_scalbln.c          |   75 ++++++
 lib/libm/src/s_sinf.c             |   62 ++++-
 lib/libm/src/s_sinl.c             |   79 ++++++
 lib/libm/src/s_tanf.c             |   53 +++-
 lib/libm/src/s_tanl.c             |   83 +++++++
 lib/libm/src/s_tgammaf.c          |   42 ++++
 lib/libm/src/s_truncl.c           |   66 +++++
 98 files changed, 6118 insertions(+), 960 deletions(-)
 create mode 100644 lib/libm/arch/i386/e_remainderl.S
 create mode 100644 lib/libm/arch/i386/e_sqrtl.S
 delete mode 100644 lib/libm/arch/i386/lrint.S
 create mode 100644 lib/libm/arch/i386/s_lrint.S
 create mode 100644 lib/libm/arch/i386/s_lrintf.S
 create mode 100644 lib/libm/arch/i386/s_lrintl.S
 create mode 100644 lib/libm/arch/i386/s_remquol.S
 create mode 100644 lib/libm/complex/s_cargl.c
 create mode 100644 lib/libm/complex/s_csqrtl.c
 create mode 100644 lib/libm/complex/w_cabsl.c
 create mode 100644 lib/libm/src/b_exp.c
 create mode 100644 lib/libm/src/b_log.c
 create mode 100644 lib/libm/src/b_tgamma.c
 create mode 100644 lib/libm/src/e_acosl.c
 create mode 100644 lib/libm/src/e_asinl.c
 create mode 100644 lib/libm/src/e_atan2l.c
 create mode 100644 lib/libm/src/e_fmodl.c
 create mode 100644 lib/libm/src/e_hypotl.c
 create mode 100644 lib/libm/src/e_rem_pio2l.h
 create mode 100644 lib/libm/src/e_remainderl.c
 create mode 100644 lib/libm/src/e_sqrtl.c
 create mode 100644 lib/libm/src/invtrig.c
 create mode 100644 lib/libm/src/invtrig.h
 create mode 100644 lib/libm/src/k_cosl.c
 create mode 100644 lib/libm/src/k_sinl.c
 create mode 100644 lib/libm/src/k_tanl.c
 delete mode 100644 lib/libm/src/llrint.c
 delete mode 100644 lib/libm/src/llrintf.c
 delete mode 100644 lib/libm/src/llround.c
 delete mode 100644 lib/libm/src/llroundf.c
 delete mode 100644 lib/libm/src/lrint.c
 delete mode 100644 lib/libm/src/lrintf.c
 delete mode 100644 lib/libm/src/lround.c
 delete mode 100644 lib/libm/src/lroundf.c
 create mode 100644 lib/libm/src/mathimpl.h
 create mode 100644 lib/libm/src/s_atanl.c
 create mode 100644 lib/libm/src/s_cbrtl.c
 create mode 100644 lib/libm/src/s_ceill.c
 create mode 100644 lib/libm/src/s_cosl.c
 create mode 100644 lib/libm/src/s_exp2l.c
 create mode 100644 lib/libm/src/s_fabs.c
 create mode 100644 lib/libm/src/s_floorl.c
 create mode 100644 lib/libm/src/s_fma.c
 create mode 100644 lib/libm/src/s_fmaf.c
 create mode 100644 lib/libm/src/s_fmal.c
 delete mode 100644 lib/libm/src/s_ldexpf.c
 create mode 100644 lib/libm/src/s_llrint.c
 create mode 100644 lib/libm/src/s_llrintf.c
 create mode 100644 lib/libm/src/s_llrintl.c
 create mode 100644 lib/libm/src/s_llround.c
 create mode 100644 lib/libm/src/s_llroundf.c
 create mode 100644 lib/libm/src/s_llroundl.c
 create mode 100644 lib/libm/src/s_lrint.c
 create mode 100644 lib/libm/src/s_lrintf.c
 create mode 100644 lib/libm/src/s_lrintl.c
 create mode 100644 lib/libm/src/s_lround.c
 create mode 100644 lib/libm/src/s_lroundf.c
 create mode 100644 lib/libm/src/s_lroundl.c
 create mode 100644 lib/libm/src/s_modf.c
 create mode 100644 lib/libm/src/s_modfl.c
 create mode 100644 lib/libm/src/s_nexttowardf.c
 create mode 100644 lib/libm/src/s_remquol.c
 create mode 100644 lib/libm/src/s_rintl.c
 create mode 100644 lib/libm/src/s_roundl.c
 create mode 100644 lib/libm/src/s_scalbln.c
 create mode 100644 lib/libm/src/s_sinl.c
 create mode 100644 lib/libm/src/s_tanl.c
 create mode 100644 lib/libm/src/s_tgammaf.c
 create mode 100644 lib/libm/src/s_truncl.c

http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/1a3b704c5cf3ce3034c25a0318f2ceaaf0eea361


-- 
DragonFly BSD source repository





More information about the Commits mailing list