Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 2 Nov 2005 06:45:22 +0000 (UTC)
From:      Bruce Evans <bde@FreeBSD.org>
To:        src-committers@FreeBSD.org, cvs-src@FreeBSD.org, cvs-all@FreeBSD.org
Subject:   cvs commit: src/lib/msun/src k_tan.c k_tanf.c
Message-ID:  <200511020645.jA26jM3O046907@repoman.freebsd.org>

next in thread | raw e-mail | index | archive | help
bde         2005-11-02 06:45:22 UTC

  FreeBSD src repository

  Modified files:
    lib/msun/src         k_tan.c k_tanf.c 
  Log:
  Removed dead code for handling tan[f]() on odd multiples of pi/2.  This
  case never occurs since pi/2 is irrational so no multiple of it can
  be represented as a float and we have precise arg reduction so we never
  end up with a remainder of 0 in the "kernel" function unless the
  original arg is 0.
  
  If this case occurs, then we would now fall through to general code
  that returns +-Inf (depending on the sign of the reduced arg) instead
  of forcing +Inf.  The correct handling would be to return NaN since
  we would have lost so much precision that the correct result can be
  anything _except_ +-Inf.
  
  Don't reindent the else clause left over from this, although it was already
  bogusly indented ("if (foo) return; else ..." just marches the indentation
  to the right), since it will be removed too.
  
  Index: k_tan.c
  ===================================================================
  RCS file: /home/ncvs/src/lib/msun/src/k_tan.c,v
  retrieving revision 1.10
  diff -r1.10 k_tan.c
  88,90c88
  <                       if (((ix | low) | (iy + 1)) == 0)
  <                               return one / fabs(x);
  <                       else {
  ---
  >                       {
  
  Revision  Changes    Path
  1.11      +1 -3      src/lib/msun/src/k_tan.c
  1.10      +1 -3      src/lib/msun/src/k_tanf.c



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200511020645.jA26jM3O046907>