Print this page
5261 libm should stop using synonyms.h
5298 fabs is 0-sized, confuses dis(1) and others
Reviewed by: Josef 'Jeff' Sipek <jeffpc@josefsipek.net>
Approved by: Gordon Ross <gwr@nexenta.com>

Split Close
Expand all
Collapse all
          --- old/usr/src/lib/libm/common/C/atan.c
          +++ new/usr/src/lib/libm/common/C/atan.c
↓ open down ↓ 19 lines elided ↑ open up ↑
  20   20   */
  21   21  
  22   22  /*
  23   23   * Copyright 2011 Nexenta Systems, Inc.  All rights reserved.
  24   24   */
  25   25  /*
  26   26   * Copyright 2006 Sun Microsystems, Inc.  All rights reserved.
  27   27   * Use is subject to license terms.
  28   28   */
  29   29  
  30      -#pragma weak atan = __atan
       30 +#pragma weak __atan = atan
  31   31  
  32   32  /* INDENT OFF */
  33   33  /*
  34   34   * atan(x)
  35   35   * Accurate Table look-up algorithm with polynomial approximation in
  36   36   * partially product form.
  37   37   *
  38   38   * -- K.C. Ng, October 17, 2004
  39   39   *
  40   40   * Algorithm
↓ open down ↓ 34 lines elided ↑ open up ↑
  75   75   *      floating point number. Calculation indicates that
  76   76   *              max|(x-y[j])/(1+x*y[j])| < 0.0154
  77   77   *              j,x
  78   78   *
  79   79   * Accuracy: Maximum error observed is bounded by 0.6 ulp after testing
  80   80   * more than 10 million random arguments
  81   81   */
  82   82  /* INDENT ON */
  83   83  
  84   84  #include "libm.h"
  85      -#include "libm_synonyms.h"
  86   85  #include "libm_protos.h"
  87   86  
  88   87  extern const double _TBL_atan[];
  89   88  static const double g[] = {
  90   89  /* one  = */  1.0,
  91   90  /* p1   = */  8.02176624254765935351230154992663301527500152588e-0002,
  92   91  /* p2   = */  1.27223421700559402580665846471674740314483642578e+0000,
  93   92  /* p3   = */ -1.20606901800503640842521235754247754812240600586e+0000,
  94   93  /* p4   = */ -2.36088967922325565496066701598465442657470703125e+0000,
  95   94  /* p5   = */  1.38345799501389166152875986881554126739501953125e+0000,
↓ open down ↓ 103 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX