This is the mail archive of the glibc-cvs@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

GNU C Library master sources branch siddhesh/benchmarks created. glibc-2.19-612-g8d9f628


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU C Library master sources".

The branch, siddhesh/benchmarks has been created
        at  8d9f628694f29800a46c6dfa95ca1ded224a0ea9 (commit)

- Log -----------------------------------------------------------------
http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=8d9f628694f29800a46c6dfa95ca1ded224a0ea9

commit 8d9f628694f29800a46c6dfa95ca1ded224a0ea9
Author: Siddhesh Poyarekar <siddhesh@redhat.com>
Date:   Mon Feb 24 23:22:24 2014 +0530

    benchtest: script to compare two benchmarks
    
    This script is a sample implementation that uses import_bench to
    construct two benchmark objects and compare them.  If detailed timing
    information is available (when one does `make DETAILED=1 bench`), it
    writes out graphs for all functions it benchmarks and prints
    significant differences in timings of the two benchmark runs.  If
    detailed timing information is not available, it points out
    significant differences in aggregate times.
    
    Call this script as follows:
    
      compare_bench.py schema_file.json bench1.out bench2.out
    
    Alternatively, if one wants to set a different threshold for warnings
    (default is a 10% difference):
    
      compare_bench.py schema_file.json bench1.out bench2.out 25
    
    The threshold in the example above is 25%.  schema_file.json is the
    JSON schema (which is $srcdir/benchtests/scripts/benchout.schema.json
    for the benchmark output file) and bench1.out and bench2.out are the
    two benchmark output files to compare.

diff --git a/benchtests/scripts/compare_bench.py b/benchtests/scripts/compare_bench.py
new file mode 100755
index 0000000..45840ff
--- /dev/null
+++ b/benchtests/scripts/compare_bench.py
@@ -0,0 +1,195 @@
+#!/usr/bin/python
+# Copyright (C) 2014 Free Software Foundation, Inc.
+# This file is part of the GNU C Library.
+#
+# The GNU C Library is free software; you can redistribute it and/or
+# modify it under the terms of the GNU Lesser General Public
+# License as published by the Free Software Foundation; either
+# version 2.1 of the License, or (at your option) any later version.
+#
+# The GNU C Library is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+# Lesser General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public
+# License along with the GNU C Library; if not, see
+# <http://www.gnu.org/licenses/>.
+"""Compare two benchmark results
+
+Given two benchmark result files and a threshold, this script compares the
+benchmark results and flags differences in performance beyond a given
+threshold.
+"""
+import sys
+import os
+import pylab
+import import_bench as bench
+
+def do_compare(func, var, tl1, tl2, par, threshold):
+    """Compare one of the aggregate measurements
+
+    Helper function to compare one of the aggregate measurements of a function
+    variant.
+
+    Args:
+        func: Function name
+        var: Function variant name
+        tl1: The first timings list
+        tl2: The second timings list
+        par: The aggregate to measure
+        threshold: The threshold for differences, beyond which the script should
+        print a warning.
+    """
+    d = abs(tl2[par] - tl1[par]) * 100 / tl1[str(par)]
+    if d > threshold:
+        if tl1[par] > tl2[par]:
+            ind = '+++'
+        else:
+            ind = '---'
+        print('%s %s(%s)[%s]: (%.2lf%%) from %g to %g' %
+                (ind, func, var, par, d, tl1[par], tl2[par]))
+
+
+def compare_runs(pts1, pts2, threshold):
+    """Compare two benchmark runs
+
+    For now, assume that machine1 and machine2 are the same.  In future, we may
+    have to add an additional condition to ensure that we are comparing apples
+    to apples.
+
+    Args:
+        machine1: Machine info from the first machine
+        machine2: machine info from the second machine
+        pts1: Timing data from first machine
+        pts2: Timing data from second machine
+    """
+    # Just print the machines for now.  We would want to do something more
+    # interesting with this in future.
+    print 'Machine 1:', pts1['machine']
+    print 'Machine 2:', pts2['machine']
+    print
+
+    # XXX We assume that the two benchmarks have identical functions and
+    # variants.  We cannot compare two benchmarks that may have different
+    # functions or variants.  Maybe that is something for the future.
+    for func in pts1['functions'].keys():
+        for var in pts1['functions'][func].keys():
+            tl1 = pts1['functions'][func][var]
+            tl2 = pts2['functions'][func][var]
+
+            # Compare the consolidated numbers
+            # do_compare(func, var, tl1, tl2, 'max', threshold)
+            do_compare(func, var, tl1, tl2, 'min', threshold)
+            do_compare(func, var, tl1, tl2, 'mean', threshold)
+
+            # Skip over to the next variant or function if there is no detailed
+            # timing info for the function variant.
+            if 'timings' not in pts1['functions'][func][var].keys() or \
+                'timings' not in pts2['functions'][func][var].keys():
+                    return
+
+            # If two lists do not have the same length then it is likely that
+            # the performance characteristics of the function have changed.
+            # XXX: It is also likely that there was some measurement that
+            # strayed outside the usual range.  Such ouiers should not
+            # happen on an idle machine with identical hardware and
+            # configuration, but ideal environments are hard to come by.
+            if len(tl1['timings']) != len(tl2['timings']):
+                print('* %s(%s): Timing characteristics changed' %
+                        (func, var))
+                print('\tBefore: [%s]' %
+                        ', '.join([str(x) for x in tl1['timings']]))
+                print('\tAfter: [%s]' %
+                        ', '.join([str(x) for x in tl2['timings']]))
+                continue
+
+            # Collect numbers whose differences cross the threshold we have
+            # set.
+            issues = [(x, y) for x, y in zip(tl1['timings'], tl2['timings']) \
+                        if abs(y - x) * 100 / x > threshold]
+
+            # Now print them.
+            for t1, t2 in issues:
+                d = abs(t2 - t1) * 100 / t1
+                if t2 > t1:
+                    ind = '-'
+                else:
+                    ind = '+'
+
+                print("%s %s(%s): (%.2lf%%) from %g to %g" %
+                        (ind, func, var, d, t1, t2))
+
+
+def plot_graphs(bench1, bench2):
+    """Plot graphs for functions
+
+    Make scatter plots for the functions and their variants.
+
+    Args:
+        bench1: Set of points from the first machine
+        bench2: Set of points from the second machine.
+    """
+    for func in bench1['functions'].keys():
+        for var in bench1['functions'][func].keys():
+            # No point trying to print a graph if there are no detailed
+            # timings.
+            if u'timings' not in bench1['functions'][func][var].keys():
+                print('Skipping graph for %s(%s)' % (func, var))
+                continue
+
+            pylab.clf()
+            pylab.ylabel('Time (cycles)')
+
+            # First set of points
+            length = len(bench1['functions'][func][var]['timings'])
+            X = [float(x) for x in range(length)]
+            lines = pylab.scatter(X, bench1['functions'][func][var]['timings'],
+                    1.5 + 100 / length)
+            pylab.setp(lines, 'color', 'r')
+
+            # Second set of points
+            length = len(bench2['functions'][func][var]['timings'])
+            X = [float(x) for x in range(length)]
+            lines = pylab.scatter(X, bench2['functions'][func][var]['timings'],
+                    1.5 + 100 / length)
+            pylab.setp(lines, 'color', 'g')
+
+            if var:
+                filename = "%s-%s.png" % (func, var)
+            else:
+                filename = "%s.png" % func
+            print('Writing out %s' % filename)
+            pylab.savefig(filename)
+
+
+def main(args):
+    """Program Entry Point
+
+    Take two benchmark output files and compare their timings.
+    """
+    if len(args) > 4 or len(args) < 3:
+        print('Usage: %s <schema> <file1> <file2> [threshold in %%]' % sys.argv[0])
+        sys.exit(os.EX_USAGE)
+
+    bench1 = bench.parse_bench(args[1], args[0])
+    bench2 = bench.parse_bench(args[2], args[0])
+    if len(args) == 4:
+        threshold = float(args[3])
+    else:
+        threshold = 10.0
+
+    if (bench1['timing-type'] != bench2['timing-type']):
+        print('Cannot compare benchmark outputs: timing types are different')
+        return
+
+    plot_graphs(bench1, bench2)
+
+    bench.compress_timings(bench1)
+    bench.compress_timings(bench2)
+
+    compare_runs(bench1, bench2, threshold)
+
+
+if __name__ == '__main__':
+    main(sys.argv[1:])

http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=61f2d06337161c5722a58a11386f8d28c171ab6c

commit 61f2d06337161c5722a58a11386f8d28c171ab6c
Author: Siddhesh Poyarekar <siddhesh@redhat.com>
Date:   Mon Feb 24 23:11:28 2014 +0530

    New script to import and process benchmark output
    
    This is a utility script to import and process benchmark outputs.  It
    loads a benchmark output file and validates it against a schema.  It
    can then compress timing data and present the benchmark object with
    reduced timings that should be representative of the detailed timings
    data.
    
    Programs can use this as a building block to construct their use cases
    for analysis of the benchmarks.

diff --git a/benchtests/scripts/import_bench.py b/benchtests/scripts/import_bench.py
new file mode 100644
index 0000000..ffcb775
--- /dev/null
+++ b/benchtests/scripts/import_bench.py
@@ -0,0 +1,141 @@
+#!/usr/bin/python
+# Copyright (C) 2014 Free Software Foundation, Inc.
+# This file is part of the GNU C Library.
+#
+# The GNU C Library is free software; you can redistribute it and/or
+# modify it under the terms of the GNU Lesser General Public
+# License as published by the Free Software Foundation; either
+# version 2.1 of the License, or (at your option) any later version.
+#
+# The GNU C Library is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+# Lesser General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public
+# License along with the GNU C Library; if not, see
+# <http://www.gnu.org/licenses/>.
+"""Functions to import benchmark data and process it"""
+
+import json
+try:
+    import jsonschema as validator
+except ImportError:
+    print('Could not find jsonschema module.')
+    raise
+
+
+def mean(lst):
+    """Compute and return mean of numbers in a list
+
+    The pypy average function has horrible performance, so implement our
+    own mean function.
+
+    Args:
+        lst: The list of numbers to average.
+    Return:
+        The mean of members in the list.
+    """
+    return sum(lst) / len(lst)
+
+
+def split_list(bench, func, var):
+    """ Split the list into a smaller set of more distinct points
+
+    Group together points such that the difference between the smallest
+    point and the mean is less than 1/3rd of the mean.  This means that
+    the mean is at most 1.5x the smallest member of that group.
+
+    mean - xmin < mean / 3
+    i.e. 2 * mean / 3 < xmin
+    i.e. mean < 3 * xmin / 2
+
+    For an evenly distributed group, the largest member will be less than
+    twice the smallest member of the group.
+    Derivation:
+
+    An evenly distributed series would be xmin, xmin + d, xmin + 2d...
+
+    mean = (2 * n * xmin + n * (n - 1) * d) / 2 * n
+    and max element is xmin + (n - 1) * d
+
+    Now, mean < 3 * xmin / 2
+
+    3 * xmin > 2 * mean
+    3 * xmin > (2 * n * xmin + n * (n - 1) * d) / n
+    3 * n * xmin > 2 * n * xmin + n * (n - 1) * d
+    n * xmin > n * (n - 1) * d
+    xmin > (n - 1) * d
+    2 * xmin > xmin + (n-1) * d
+    2 * xmin > xmax
+
+    Hence, proved.
+
+    Similarly, it is trivial to prove that for a similar aggregation by using
+    the maximum element, the maximum element in the group must be at most 4/3
+    times the mean.
+
+    Args:
+        bench: The benchmark object
+        func: The function name
+        var: The function variant name
+    """
+    means = []
+    lst = bench['functions'][func][var]['timings']
+    last = len(lst) - 1
+    while lst:
+        for i in range(last + 1):
+            avg = mean(lst[i:])
+            if avg > 0.75 * lst[last]:
+                means.insert(0, avg)
+                lst = lst[:i]
+                last = i - 1
+                break
+    bench['functions'][func][var]['timings'] = means
+
+
+def do_for_all_timings(bench, callback):
+    """Call a function for all timing objects for each function and its
+    variants.
+
+    Args:
+        bench: The benchmark object
+        callback: The callback function
+    """
+    for func in bench['functions'].keys():
+        for k in bench['functions'][func].keys():
+            if 'timings' not in bench['functions'][func][k].keys():
+                continue
+
+            callback(bench, func, k)
+
+
+def compress_timings(points):
+    """Club points with close enough values into a single mean value
+
+    See split_list for details on how the clubbing is done.
+
+    Args:
+        points: The set of points.
+    """
+    do_for_all_timings(points, split_list)
+
+
+def parse_bench(filename, schema_filename):
+    """Parse the input file
+
+    Parse and validate the json file containing the benchmark outputs.  Return
+    the resulting object.
+    Args:
+        filename: Name of the benchmark output file.
+    Return:
+        The bench dictionary.
+    """
+    with open(schema_filename, 'r') as schemafile:
+        schema = json.load(schemafile)
+        with open(filename, 'r') as benchfile:
+            bench = json.load(benchfile)
+            validator.validate(bench, schema)
+            do_for_all_timings(bench, lambda b, f, v:
+                    b['functions'][f][v]['timings'].sort())
+            return bench
diff --git a/benchtests/scripts/validate_benchout.py b/benchtests/scripts/validate_benchout.py
index 61a8cbd..9d3a5cb 100755
--- a/benchtests/scripts/validate_benchout.py
+++ b/benchtests/scripts/validate_benchout.py
@@ -27,37 +27,26 @@ import sys
 import os
 
 try:
-    import jsonschema
+    import import_bench as bench
 except ImportError:
-    print('Could not find jsonschema module.  Output not validated.')
+    print('Import Error: Output will not be validated.')
     # Return success because we don't want the bench target to fail just
     # because the jsonschema module was not found.
     sys.exit(os.EX_OK)
 
 
-def validate_bench(benchfile, schemafile):
-    """Validate benchmark file
-
-    Validate a benchmark output file against a JSON schema.
+def print_and_exit(message, exitcode):
+    """Prints message to stderr and returns the exit code.
 
     Args:
-        benchfile: The file name of the bench.out file.
-        schemafile: The file name of the JSON schema file to validate
-        bench.out against.
+        message: The message to print
+        exitcode: The exit code to return
 
-    Exceptions:
-        jsonschema.ValidationError: When bench.out is not valid
-        jsonschema.SchemaError: When the JSON schema is not valid
-        IOError: If any of the files are not found.
+    Returns:
+        The passed exit code
     """
-    with open(benchfile, 'r') as bfile:
-        with open(schemafile, 'r') as sfile:
-            bench = json.load(bfile)
-            schema = json.load(sfile)
-            jsonschema.validate(bench, schema)
-
-    # If we reach here, we're all good.
-    print("Benchmark output in %s is valid." % benchfile)
+    print(message, file=sys.stderr)
+    return exitcode
 
 
 def main(args):
@@ -73,11 +62,23 @@ def main(args):
         Exceptions thrown by validate_bench
     """
     if len(args) != 2:
-        print("Usage: %s <bench.out file> <bench.out schema>" % sys.argv[0],
-                file=sys.stderr)
-        return os.EX_USAGE
+        return print_and_exit("Usage: %s <bench.out file> <bench.out schema>"
+                % sys.argv[0], os.EX_USAGE)
+
+    try:
+        bench.parse_bench(args[0], args[1])
+    except IOError as e:
+        return print_and_exit("IOError(%d): %s" % (e.errno, e.strerror),
+                os.EX_OSFILE)
+
+    except bench.validator.ValidationError as e:
+        return print_and_exit("Invalid benchmark output: %s" % e.message,
+            os.EX_DATAERR)
+
+    except bench.validator.SchemaError as e:
+        return print_and_exit("Invalid schema: %s" % e.message, os.EX_DATAERR)
 
-    validate_bench(args[0], args[1])
+    print("Benchmark output in %s is valid." % args[0])
     return os.EX_OK
 
 

http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=f67c07e5640946b41314f118b2fa6f465d7da48a

commit f67c07e5640946b41314f118b2fa6f465d7da48a
Author: Siddhesh Poyarekar <siddhesh@redhat.com>
Date:   Tue Oct 8 16:36:19 2013 +0530

    TMP: probes for math functions
    
    Temporary probes at various branch points in the functions.

diff --git a/sysdeps/ieee754/dbl-64/e_asin.c b/sysdeps/ieee754/dbl-64/e_asin.c
index 5bb5aeb..d425fd7 100644
--- a/sysdeps/ieee754/dbl-64/e_asin.c
+++ b/sysdeps/ieee754/dbl-64/e_asin.c
@@ -40,17 +40,18 @@
 #include "MathLib.h"
 #include "uasncs.h"
 #include <math_private.h>
+#include <stap-probe.h>
 
 #ifndef SECTION
 # define SECTION
 #endif
 
-void __doasin(double x, double dx, double w[]);
-void __dubsin(double x, double dx, double v[]);
-void __dubcos(double x, double dx, double v[]);
-void __docos(double x, double dx, double v[]);
-double __sin32(double x, double res, double res1);
-double __cos32(double x, double res, double res1);
+void __doasin (double x, double dx, double w[]);
+void __dubsin (double x, double dx, double v[]);
+void __dubcos (double x, double dx, double v[]);
+void __docos (double x, double dx, double v[]);
+double __sin32 (double x, double res, double res1);
+double __cos32 (double x, double res, double res1);
 
 /***************************************************************************/
 /* An ultimate asin routine. Given an IEEE double machine number x         */
@@ -58,584 +59,1044 @@ double __cos32(double x, double res, double res1);
 /***************************************************************************/
 double
 SECTION
-__ieee754_asin(double x){
-  double x1,x2,xx,s1,s2,res1,p,t,res,r,cor,cc,y,c,z,w[2];
-  mynumber u,v;
-  int4 k,m,n;
+__ieee754_asin (double x)
+{
+  double x1, x2, xx, s1, s2, res1, p, t, res, r, cor, cc, y, c, z, w[2];
+  mynumber u, v;
+  int4 k, m, n;
 
   u.x = x;
   m = u.i[HIGH_HALF];
-  k = 0x7fffffff&m;              /* no sign */
+  k = 0x7fffffff & m;		/* no sign */
 
-  if (k < 0x3e500000) return x;  /* for x->0 => sin(x)=x */
+  if (k < 0x3e500000)
+    return x;			/* for x->0 => sin(x)=x */
   /*----------------------2^-26 <= |x| < 2^ -3    -----------------*/
-  else
-  if (k < 0x3fc00000) {
-    x2 = x*x;
-    t = (((((f6*x2 + f5)*x2 + f4)*x2 + f3)*x2 + f2)*x2 + f1)*(x2*x);
-    res = x+t;         /*  res=arcsin(x) according to Taylor series  */
-    cor = (x-res)+t;
-    if (res == res+1.025*cor) return res;
-    else {
-      x1 = x+big;
-      xx = x*x;
-      x1 -= big;
-      x2 = x - x1;
-      p = x1*x1*x1;
-      s1 = a1.x*p;
-      s2 = ((((((c7*xx + c6)*xx + c5)*xx + c4)*xx + c3)*xx + c2)*xx*xx*x +
-	     ((a1.x+a2.x)*x2*x2+ 0.5*x1*x)*x2) + a2.x*p;
-      res1 = x+s1;
-      s2 = ((x-res1)+s1)+s2;
-      res = res1+s2;
-      cor = (res1-res)+s2;
-      if (res == res+1.00014*cor) return res;
-      else {
-	__doasin(x,0,w);
-	if (w[0]==(w[0]+1.00000001*w[1])) return w[0];
-	else {
-	  y=ABS(x);
-	  res=ABS(w[0]);
-	  res1=ABS(w[0]+1.1*w[1]);
-	  return (m>0)?__sin32(y,res,res1):-__sin32(y,res,res1);
-	}
-      }
+  else if (k < 0x3fc00000)
+    {
+      x2 = x * x;
+      t =
+	(((((f6 * x2 + f5) * x2 + f4) * x2 + f3) * x2 + f2) * x2 +
+	 f1) * (x2 * x);
+      res = x + t;		/*  res=arcsin(x) according to Taylor series  */
+      cor = (x - res) + t;
+      if (res == res + 1.025 * cor)
+        {
+	  LIBC_PROBE (asin_probe, 2, 1, &x);
+	  return res;
+	}
+      else
+	{
+	  x1 = x + big;
+	  xx = x * x;
+	  x1 -= big;
+	  x2 = x - x1;
+	  p = x1 * x1 * x1;
+	  s1 = a1.x * p;
+	  s2 =
+	    ((((((c7 * xx + c6) * xx + c5) * xx + c4) * xx + c3) * xx +
+	      c2) * xx * xx * x + ((a1.x + a2.x) * x2 * x2 +
+				   0.5 * x1 * x) * x2) + a2.x * p;
+	  res1 = x + s1;
+	  s2 = ((x - res1) + s1) + s2;
+	  res = res1 + s2;
+	  cor = (res1 - res) + s2;
+	  if (res == res + 1.00014 * cor)
+	    {
+	  LIBC_PROBE (asin_probe, 2, 2, &x);
+	    return res;
+	    }
+	  else
+	    {
+	      __doasin (x, 0, w);
+	      if (w[0] == (w[0] + 1.00000001 * w[1]))
+	      {
+	  LIBC_PROBE (asin_probe, 2, 3, &x);
+		return w[0];
+		}
+	      else
+		{
+		  y = ABS (x);
+		  res = ABS (w[0]);
+		  res1 = ABS (w[0] + 1.1 * w[1]);
+		  return (m > 0) ? __sin32 (y, res, res1) : -__sin32 (y, res,
+								      res1);
+		}
+	    }
+	}
     }
-  }
   /*---------------------0.125 <= |x| < 0.5 -----------------------------*/
-  else if (k < 0x3fe00000) {
-    if (k<0x3fd00000) n = 11*((k&0x000fffff)>>15);
-    else n = 11*((k&0x000fffff)>>14)+352;
-    if (m>0) xx = x - asncs.x[n];
-    else xx = -x - asncs.x[n];
-    t = asncs.x[n+1]*xx;
-    p=xx*xx*(asncs.x[n+2]+xx*(asncs.x[n+3]+xx*(asncs.x[n+4]+xx*(asncs.x[n+5]
-     +xx*asncs.x[n+6]))))+asncs.x[n+7];
-    t+=p;
-    res =asncs.x[n+8] +t;
-    cor = (asncs.x[n+8]-res)+t;
-    if (res == res+1.05*cor) return (m>0)?res:-res;
-    else {
-      r=asncs.x[n+8]+xx*asncs.x[n+9];
-      t=((asncs.x[n+8]-r)+xx*asncs.x[n+9])+(p+xx*asncs.x[n+10]);
-      res = r+t;
-      cor = (r-res)+t;
-      if (res == res+1.0005*cor) return (m>0)?res:-res;
-      else {
-	res1=res+1.1*cor;
-	z=0.5*(res1-res);
-	__dubsin(res,z,w);
-	z=(w[0]-ABS(x))+w[1];
-	if (z>1.0e-27) return (m>0)?min(res,res1):-min(res,res1);
-	else if (z<-1.0e-27) return (m>0)?max(res,res1):-max(res,res1);
-	else {
-	  y=ABS(x);
-	  return (m>0)?__sin32(y,res,res1):-__sin32(y,res,res1);
-	}
-      }
-    }
-  }    /*   else  if (k < 0x3fe00000)    */
+  else if (k < 0x3fe00000)
+    {
+      if (k < 0x3fd00000)
+	n = 11 * ((k & 0x000fffff) >> 15);
+      else
+	n = 11 * ((k & 0x000fffff) >> 14) + 352;
+      if (m > 0)
+	xx = x - asncs.x[n];
+      else
+	xx = -x - asncs.x[n];
+      t = asncs.x[n + 1] * xx;
+      p =
+	xx * xx * (asncs.x[n + 2] +
+		   xx * (asncs.x[n + 3] +
+			 xx * (asncs.x[n + 4] +
+			       xx * (asncs.x[n + 5] +
+				     xx * asncs.x[n + 6])))) + asncs.x[n + 7];
+      t += p;
+      res = asncs.x[n + 8] + t;
+      cor = (asncs.x[n + 8] - res) + t;
+      if (res == res + 1.05 * cor)
+{
+	  LIBC_PROBE (asin_probe, 2, 4, &x);
+	return (m > 0) ? res : -res;
+	}
+      else
+	{
+	  r = asncs.x[n + 8] + xx * asncs.x[n + 9];
+	  t =
+	    ((asncs.x[n + 8] - r) + xx * asncs.x[n + 9]) + (p +
+							    xx * asncs.x[n +
+									 10]);
+	  res = r + t;
+	  cor = (r - res) + t;
+	  if (res == res + 1.0005 * cor)
+	  {
+	  LIBC_PROBE (asin_probe, 2, 5, &x);
+	    return (m > 0) ? res : -res;
+	    }
+	  else
+	    {
+	      res1 = res + 1.1 * cor;
+	      z = 0.5 * (res1 - res);
+	      __dubsin (res, z, w);
+	      z = (w[0] - ABS (x)) + w[1];
+	      if (z > 1.0e-27)
+	      {
+	  LIBC_PROBE (asin_probe, 2, 6, &x);
+		return (m > 0) ? min (res, res1) : -min (res, res1);
+		}
+	      else if (z < -1.0e-27)
+	      {
+	  LIBC_PROBE (asin_probe, 2, 7, &x);
+		return (m > 0) ? max (res, res1) : -max (res, res1);
+		}
+	      else
+		{
+		  y = ABS (x);
+		  return (m > 0) ? __sin32 (y, res, res1) : -__sin32 (y, res,
+								      res1);
+		}
+	    }
+	}
+    }				/*   else  if (k < 0x3fe00000)    */
   /*-------------------- 0.5 <= |x| < 0.75 -----------------------------*/
-  else
-  if (k < 0x3fe80000) {
-    n = 1056+((k&0x000fe000)>>11)*3;
-    if (m>0) xx = x - asncs.x[n];
-    else xx = -x - asncs.x[n];
-    t = asncs.x[n+1]*xx;
-    p=xx*xx*(asncs.x[n+2]+xx*(asncs.x[n+3]+xx*(asncs.x[n+4]+xx*(asncs.x[n+5]
-	   +xx*(asncs.x[n+6]+xx*asncs.x[n+7])))))+asncs.x[n+8];
-    t+=p;
-    res =asncs.x[n+9] +t;
-    cor = (asncs.x[n+9]-res)+t;
-    if (res == res+1.01*cor) return (m>0)?res:-res;
-    else {
-      r=asncs.x[n+9]+xx*asncs.x[n+10];
-      t=((asncs.x[n+9]-r)+xx*asncs.x[n+10])+(p+xx*asncs.x[n+11]);
-      res = r+t;
-      cor = (r-res)+t;
-      if (res == res+1.0005*cor) return (m>0)?res:-res;
-      else {
-	res1=res+1.1*cor;
-	z=0.5*(res1-res);
-	__dubsin(res,z,w);
-	z=(w[0]-ABS(x))+w[1];
-	if (z>1.0e-27) return (m>0)?min(res,res1):-min(res,res1);
-	else if (z<-1.0e-27) return (m>0)?max(res,res1):-max(res,res1);
-	else {
-	  y=ABS(x);
-	  return (m>0)?__sin32(y,res,res1):-__sin32(y,res,res1);
-	}
-      }
-    }
-  }    /*   else  if (k < 0x3fe80000)    */
+  else if (k < 0x3fe80000)
+    {
+      n = 1056 + ((k & 0x000fe000) >> 11) * 3;
+      if (m > 0)
+	xx = x - asncs.x[n];
+      else
+	xx = -x - asncs.x[n];
+      t = asncs.x[n + 1] * xx;
+      p =
+	xx * xx * (asncs.x[n + 2] +
+		   xx * (asncs.x[n + 3] +
+			 xx * (asncs.x[n + 4] +
+			       xx * (asncs.x[n + 5] +
+				     xx * (asncs.x[n + 6] +
+					   xx * asncs.x[n + 7]))))) +
+	asncs.x[n + 8];
+      t += p;
+      res = asncs.x[n + 9] + t;
+      cor = (asncs.x[n + 9] - res) + t;
+      if (res == res + 1.01 * cor)
+      {
+	  LIBC_PROBE (asin_probe, 2, 8, &x);
+	return (m > 0) ? res : -res;
+	}
+      else
+	{
+	  r = asncs.x[n + 9] + xx * asncs.x[n + 10];
+	  t =
+	    ((asncs.x[n + 9] - r) + xx * asncs.x[n + 10]) + (p +
+							     xx * asncs.x[n +
+									  11]);
+	  res = r + t;
+	  cor = (r - res) + t;
+	  if (res == res + 1.0005 * cor)
+	  {
+	  LIBC_PROBE (asin_probe, 2, 9, &x);
+	    return (m > 0) ? res : -res;
+	    }
+	  else
+	    {
+	      res1 = res + 1.1 * cor;
+	      z = 0.5 * (res1 - res);
+	      __dubsin (res, z, w);
+	      z = (w[0] - ABS (x)) + w[1];
+	      if (z > 1.0e-27)
+	      {
+	  LIBC_PROBE (asin_probe, 2, 10, &x);
+		return (m > 0) ? min (res, res1) : -min (res, res1);
+		}
+	      else if (z < -1.0e-27)
+	      {
+	  LIBC_PROBE (asin_probe, 2, 11, &x);
+		return (m > 0) ? max (res, res1) : -max (res, res1);
+		}
+	      else
+		{
+		  y = ABS (x);
+		  return (m > 0) ? __sin32 (y, res, res1) : -__sin32 (y, res,
+								      res1);
+		}
+	    }
+	}
+    }				/*   else  if (k < 0x3fe80000)    */
   /*--------------------- 0.75 <= |x|< 0.921875 ----------------------*/
-  else
-  if (k < 0x3fed8000) {
-    n = 992+((k&0x000fe000)>>13)*13;
-    if (m>0) xx = x - asncs.x[n];
-    else xx = -x - asncs.x[n];
-    t = asncs.x[n+1]*xx;
-    p=xx*xx*(asncs.x[n+2]+xx*(asncs.x[n+3]+xx*(asncs.x[n+4]+xx*(asncs.x[n+5]
-     +xx*(asncs.x[n+6]+xx*(asncs.x[n+7]+xx*asncs.x[n+8]))))))+asncs.x[n+9];
-    t+=p;
-    res =asncs.x[n+10] +t;
-    cor = (asncs.x[n+10]-res)+t;
-    if (res == res+1.01*cor) return (m>0)?res:-res;
-    else {
-      r=asncs.x[n+10]+xx*asncs.x[n+11];
-      t=((asncs.x[n+10]-r)+xx*asncs.x[n+11])+(p+xx*asncs.x[n+12]);
-      res = r+t;
-      cor = (r-res)+t;
-      if (res == res+1.0008*cor) return (m>0)?res:-res;
-      else {
-	res1=res+1.1*cor;
-	z=0.5*(res1-res);
-	y=hp0.x-res;
-	z=((hp0.x-y)-res)+(hp1.x-z);
-	__dubcos(y,z,w);
-	z=(w[0]-ABS(x))+w[1];
-	if (z>1.0e-27) return (m>0)?min(res,res1):-min(res,res1);
-	else if (z<-1.0e-27) return (m>0)?max(res,res1):-max(res,res1);
-	else {
-	  y=ABS(x);
-	  return (m>0)?__sin32(y,res,res1):-__sin32(y,res,res1);
-	}
-      }
-    }
-  }    /*   else  if (k < 0x3fed8000)    */
+  else if (k < 0x3fed8000)
+    {
+      n = 992 + ((k & 0x000fe000) >> 13) * 13;
+      if (m > 0)
+	xx = x - asncs.x[n];
+      else
+	xx = -x - asncs.x[n];
+      t = asncs.x[n + 1] * xx;
+      p =
+	xx * xx * (asncs.x[n + 2] +
+		   xx * (asncs.x[n + 3] +
+			 xx * (asncs.x[n + 4] +
+			       xx * (asncs.x[n + 5] +
+				     xx * (asncs.x[n + 6] +
+					   xx * (asncs.x[n + 7] +
+						 xx * asncs.x[n + 8])))))) +
+	asncs.x[n + 9];
+      t += p;
+      res = asncs.x[n + 10] + t;
+      cor = (asncs.x[n + 10] - res) + t;
+      if (res == res + 1.01 * cor)
+      {
+	  LIBC_PROBE (asin_probe, 2, 12, &x);
+	return (m > 0) ? res : -res;
+	}
+      else
+	{
+	  r = asncs.x[n + 10] + xx * asncs.x[n + 11];
+	  t =
+	    ((asncs.x[n + 10] - r) + xx * asncs.x[n + 11]) + (p +
+							      xx * asncs.x[n +
+									   12]);
+	  res = r + t;
+	  cor = (r - res) + t;
+	  if (res == res + 1.0008 * cor)
+	  {
+	  LIBC_PROBE (asin_probe, 2, 13, &x);
+	    return (m > 0) ? res : -res;
+	    }
+	  else
+	    {
+	      res1 = res + 1.1 * cor;
+	      z = 0.5 * (res1 - res);
+	      y = hp0.x - res;
+	      z = ((hp0.x - y) - res) + (hp1.x - z);
+	      __dubcos (y, z, w);
+	      z = (w[0] - ABS (x)) + w[1];
+	      if (z > 1.0e-27)
+	      {
+	  LIBC_PROBE (asin_probe, 2, 14, &x);
+		return (m > 0) ? min (res, res1) : -min (res, res1);
+		}
+	      else if (z < -1.0e-27)
+	      {
+	  LIBC_PROBE (asin_probe, 2, 15, &x);
+		return (m > 0) ? max (res, res1) : -max (res, res1);
+		}
+	      else
+		{
+		  y = ABS (x);
+		  return (m > 0) ? __sin32 (y, res, res1) : -__sin32 (y, res,
+								      res1);
+		}
+	    }
+	}
+    }				/*   else  if (k < 0x3fed8000)    */
   /*-------------------0.921875 <= |x| < 0.953125 ------------------------*/
-  else
-  if (k < 0x3fee8000) {
-    n = 884+((k&0x000fe000)>>13)*14;
-    if (m>0) xx = x - asncs.x[n];
-    else xx = -x - asncs.x[n];
-    t = asncs.x[n+1]*xx;
-    p=xx*xx*(asncs.x[n+2]+xx*(asncs.x[n+3]+xx*(asncs.x[n+4]+
-		      xx*(asncs.x[n+5]+xx*(asncs.x[n+6]
-		      +xx*(asncs.x[n+7]+xx*(asncs.x[n+8]+
-		      xx*asncs.x[n+9])))))))+asncs.x[n+10];
-    t+=p;
-    res =asncs.x[n+11] +t;
-    cor = (asncs.x[n+11]-res)+t;
-    if (res == res+1.01*cor) return (m>0)?res:-res;
-    else {
-      r=asncs.x[n+11]+xx*asncs.x[n+12];
-      t=((asncs.x[n+11]-r)+xx*asncs.x[n+12])+(p+xx*asncs.x[n+13]);
-      res = r+t;
-      cor = (r-res)+t;
-      if (res == res+1.0007*cor) return (m>0)?res:-res;
-      else {
-	res1=res+1.1*cor;
-	z=0.5*(res1-res);
-	y=(hp0.x-res)-z;
-	z=y+hp1.x;
-	y=(y-z)+hp1.x;
-	__dubcos(z,y,w);
-	z=(w[0]-ABS(x))+w[1];
-	if (z>1.0e-27) return (m>0)?min(res,res1):-min(res,res1);
-	else if (z<-1.0e-27) return (m>0)?max(res,res1):-max(res,res1);
-	else {
-	  y=ABS(x);
-	  return (m>0)?__sin32(y,res,res1):-__sin32(y,res,res1);
-	}
-      }
-    }
-  }    /*   else  if (k < 0x3fee8000)    */
+  else if (k < 0x3fee8000)
+    {
+      n = 884 + ((k & 0x000fe000) >> 13) * 14;
+      if (m > 0)
+	xx = x - asncs.x[n];
+      else
+	xx = -x - asncs.x[n];
+      t = asncs.x[n + 1] * xx;
+      p =
+	xx * xx * (asncs.x[n + 2] +
+		   xx * (asncs.x[n + 3] +
+			 xx * (asncs.x[n + 4] +
+			       xx * (asncs.x[n + 5] +
+				     xx * (asncs.x[n + 6] +
+					   xx * (asncs.x[n + 7] +
+						 xx * (asncs.x[n + 8] +
+						       xx * asncs.x[n +
+								    9])))))))
+	+ asncs.x[n + 10];
+      t += p;
+      res = asncs.x[n + 11] + t;
+      cor = (asncs.x[n + 11] - res) + t;
+      if (res == res + 1.01 * cor)
+      {
+	  LIBC_PROBE (asin_probe, 2, 16, &x);
+	return (m > 0) ? res : -res;
+	}
+      else
+	{
+	  r = asncs.x[n + 11] + xx * asncs.x[n + 12];
+	  t =
+	    ((asncs.x[n + 11] - r) + xx * asncs.x[n + 12]) + (p +
+							      xx * asncs.x[n +
+									   13]);
+	  res = r + t;
+	  cor = (r - res) + t;
+	  if (res == res + 1.0007 * cor)
+	  {
+	  LIBC_PROBE (asin_probe, 2, 17, &x);
+	    return (m > 0) ? res : -res;
+	    }
+	  else
+	    {
+	      res1 = res + 1.1 * cor;
+	      z = 0.5 * (res1 - res);
+	      y = (hp0.x - res) - z;
+	      z = y + hp1.x;
+	      y = (y - z) + hp1.x;
+	      __dubcos (z, y, w);
+	      z = (w[0] - ABS (x)) + w[1];
+	      if (z > 1.0e-27)
+	      {
+	  LIBC_PROBE (asin_probe, 2, 18, &x);
+		return (m > 0) ? min (res, res1) : -min (res, res1);
+		}
+	      else if (z < -1.0e-27)
+	      {
+	  LIBC_PROBE (asin_probe, 2, 19, &x);
+		return (m > 0) ? max (res, res1) : -max (res, res1);
+		}
+	      else
+		{
+		  y = ABS (x);
+		  return (m > 0) ? __sin32 (y, res, res1) : -__sin32 (y, res,
+								      res1);
+		}
+	    }
+	}
+    }				/*   else  if (k < 0x3fee8000)    */
 
   /*--------------------0.953125 <= |x| < 0.96875 ------------------------*/
-  else
-  if (k < 0x3fef0000) {
-    n = 768+((k&0x000fe000)>>13)*15;
-    if (m>0) xx = x - asncs.x[n];
-    else xx = -x - asncs.x[n];
-    t = asncs.x[n+1]*xx;
-    p=xx*xx*(asncs.x[n+2]+xx*(asncs.x[n+3]+xx*(asncs.x[n+4]+
-			 xx*(asncs.x[n+5]+xx*(asncs.x[n+6]
-			 +xx*(asncs.x[n+7]+xx*(asncs.x[n+8]+
-		    xx*(asncs.x[n+9]+xx*asncs.x[n+10]))))))))+asncs.x[n+11];
-    t+=p;
-    res =asncs.x[n+12] +t;
-    cor = (asncs.x[n+12]-res)+t;
-    if (res == res+1.01*cor) return (m>0)?res:-res;
-    else {
-      r=asncs.x[n+12]+xx*asncs.x[n+13];
-      t=((asncs.x[n+12]-r)+xx*asncs.x[n+13])+(p+xx*asncs.x[n+14]);
-      res = r+t;
-      cor = (r-res)+t;
-      if (res == res+1.0007*cor) return (m>0)?res:-res;
-      else {
-	res1=res+1.1*cor;
-	z=0.5*(res1-res);
-	y=(hp0.x-res)-z;
-	z=y+hp1.x;
-	y=(y-z)+hp1.x;
-	__dubcos(z,y,w);
-	z=(w[0]-ABS(x))+w[1];
-	if (z>1.0e-27) return (m>0)?min(res,res1):-min(res,res1);
-	else if (z<-1.0e-27) return (m>0)?max(res,res1):-max(res,res1);
-	else {
-	  y=ABS(x);
-	  return (m>0)?__sin32(y,res,res1):-__sin32(y,res,res1);
-	}
-      }
-    }
-  }    /*   else  if (k < 0x3fef0000)    */
+  else if (k < 0x3fef0000)
+    {
+      n = 768 + ((k & 0x000fe000) >> 13) * 15;
+      if (m > 0)
+	xx = x - asncs.x[n];
+      else
+	xx = -x - asncs.x[n];
+      t = asncs.x[n + 1] * xx;
+      p =
+	xx * xx * (asncs.x[n + 2] +
+		   xx * (asncs.x[n + 3] +
+			 xx * (asncs.x[n + 4] +
+			       xx * (asncs.x[n + 5] +
+				     xx * (asncs.x[n + 6] +
+					   xx * (asncs.x[n + 7] +
+						 xx * (asncs.x[n + 8] +
+						       xx * (asncs.x[n + 9] +
+							     xx * asncs.x[n +
+									  10]))))))))
+	+ asncs.x[n + 11];
+      t += p;
+      res = asncs.x[n + 12] + t;
+      cor = (asncs.x[n + 12] - res) + t;
+      if (res == res + 1.01 * cor)
+      {
+	  LIBC_PROBE (asin_probe, 2, 20, &x);
+	return (m > 0) ? res : -res;
+	}
+      else
+	{
+	  r = asncs.x[n + 12] + xx * asncs.x[n + 13];
+	  t =
+	    ((asncs.x[n + 12] - r) + xx * asncs.x[n + 13]) + (p +
+							      xx * asncs.x[n +
+									   14]);
+	  res = r + t;
+	  cor = (r - res) + t;
+	  if (res == res + 1.0007 * cor)
+	  {
+	  LIBC_PROBE (asin_probe, 2, 21, &x);
+	    return (m > 0) ? res : -res;
+	    }
+	  else
+	    {
+	      res1 = res + 1.1 * cor;
+	      z = 0.5 * (res1 - res);
+	      y = (hp0.x - res) - z;
+	      z = y + hp1.x;
+	      y = (y - z) + hp1.x;
+	      __dubcos (z, y, w);
+	      z = (w[0] - ABS (x)) + w[1];
+	      if (z > 1.0e-27)
+	      {
+	  LIBC_PROBE (asin_probe, 2, 22, &x);
+		return (m > 0) ? min (res, res1) : -min (res, res1);
+		}
+	      else if (z < -1.0e-27)
+	      {
+	  LIBC_PROBE (asin_probe, 2, 23, &x);
+		return (m > 0) ? max (res, res1) : -max (res, res1);
+		}
+	      else
+		{
+		  y = ABS (x);
+		  return (m > 0) ? __sin32 (y, res, res1) : -__sin32 (y, res,
+								      res1);
+		}
+	    }
+	}
+    }				/*   else  if (k < 0x3fef0000)    */
   /*--------------------0.96875 <= |x| < 1 --------------------------------*/
-  else
-  if (k<0x3ff00000)  {
-    z = 0.5*((m>0)?(1.0-x):(1.0+x));
-    v.x=z;
-    k=v.i[HIGH_HALF];
-    t=inroot[(k&0x001fffff)>>14]*powtwo[511-(k>>21)];
-    r=1.0-t*t*z;
-    t = t*(rt0+r*(rt1+r*(rt2+r*rt3)));
-    c=t*z;
-    t=c*(1.5-0.5*t*c);
-    y=(c+t24)-t24;
-    cc = (z-y*y)/(t+y);
-    p=(((((f6*z+f5)*z+f4)*z+f3)*z+f2)*z+f1)*z;
-    cor = (hp1.x - 2.0*cc)-2.0*(y+cc)*p;
-    res1 = hp0.x - 2.0*y;
-    res =res1 + cor;
-    if (res == res+1.003*((res1-res)+cor)) return (m>0)?res:-res;
-    else {
-      c=y+cc;
-      cc=(y-c)+cc;
-      __doasin(c,cc,w);
-      res1=hp0.x-2.0*w[0];
-      cor=((hp0.x-res1)-2.0*w[0])+(hp1.x-2.0*w[1]);
-      res = res1+cor;
-      cor = (res1-res)+cor;
-      if (res==(res+1.0000001*cor)) return (m>0)?res:-res;
-      else {
-	y=ABS(x);
-	res1=res+1.1*cor;
-	return (m>0)?__sin32(y,res,res1):-__sin32(y,res,res1);
-      }
-    }
-  }    /*   else  if (k < 0x3ff00000)    */
+  else if (k < 0x3ff00000)
+    {
+      z = 0.5 * ((m > 0) ? (1.0 - x) : (1.0 + x));
+      v.x = z;
+      k = v.i[HIGH_HALF];
+      t = inroot[(k & 0x001fffff) >> 14] * powtwo[511 - (k >> 21)];
+      r = 1.0 - t * t * z;
+      t = t * (rt0 + r * (rt1 + r * (rt2 + r * rt3)));
+      c = t * z;
+      t = c * (1.5 - 0.5 * t * c);
+      y = (c + t24) - t24;
+      cc = (z - y * y) / (t + y);
+      p = (((((f6 * z + f5) * z + f4) * z + f3) * z + f2) * z + f1) * z;
+      cor = (hp1.x - 2.0 * cc) - 2.0 * (y + cc) * p;
+      res1 = hp0.x - 2.0 * y;
+      res = res1 + cor;
+      if (res == res + 1.003 * ((res1 - res) + cor))
+      {
+	  LIBC_PROBE (asin_probe, 2, 24, &x);
+	return (m > 0) ? res : -res;
+	}
+      else
+	{
+	  c = y + cc;
+	  cc = (y - c) + cc;
+	  __doasin (c, cc, w);
+	  res1 = hp0.x - 2.0 * w[0];
+	  cor = ((hp0.x - res1) - 2.0 * w[0]) + (hp1.x - 2.0 * w[1]);
+	  res = res1 + cor;
+	  cor = (res1 - res) + cor;
+	  if (res == (res + 1.0000001 * cor))
+	  {
+	  LIBC_PROBE (asin_probe, 2, 25, &x);
+	    return (m > 0) ? res : -res;
+	    }
+	  else
+	    {
+	      y = ABS (x);
+	      res1 = res + 1.1 * cor;
+	      return (m > 0) ? __sin32 (y, res, res1) : -__sin32 (y, res,
+								  res1);
+	    }
+	}
+    }				/*   else  if (k < 0x3ff00000)    */
   /*---------------------------- |x|>=1 -------------------------------*/
-  else if (k==0x3ff00000 && u.i[LOW_HALF]==0) return (m>0)?hp0.x:-hp0.x;
+  else if (k == 0x3ff00000 && u.i[LOW_HALF] == 0)
+    return (m > 0) ? hp0.x : -hp0.x;
+  else if (k > 0x7ff00000 || (k == 0x7ff00000 && u.i[LOW_HALF] != 0))
+    return x;
   else
-  if (k>0x7ff00000 || (k == 0x7ff00000 && u.i[LOW_HALF] != 0)) return x;
-  else {
-    u.i[HIGH_HALF]=0x7ff00000;
-    v.i[HIGH_HALF]=0x7ff00000;
-    u.i[LOW_HALF]=0;
-    v.i[LOW_HALF]=0;
-    return u.x/v.x;  /* NaN */
- }
+    {
+      u.i[HIGH_HALF] = 0x7ff00000;
+      v.i[HIGH_HALF] = 0x7ff00000;
+      u.i[LOW_HALF] = 0;
+      v.i[LOW_HALF] = 0;
+      return u.x / v.x;		/* NaN */
+    }
 }
+
 #ifndef __ieee754_asin
 strong_alias (__ieee754_asin, __asin_finite)
 #endif
-
 /*******************************************************************/
 /*                                                                 */
 /*         End of arcsine,  below is arccosine                     */
 /*                                                                 */
 /*******************************************************************/
-
 double
 SECTION
-__ieee754_acos(double x)
+__ieee754_acos (double x)
 {
-  double x1,x2,xx,s1,s2,res1,p,t,res,r,cor,cc,y,c,z,w[2],eps;
-  mynumber u,v;
-  int4 k,m,n;
+  double x1, x2, xx, s1, s2, res1, p, t, res, r, cor, cc, y, c, z, w[2], eps;
+  mynumber u, v;
+  int4 k, m, n;
   u.x = x;
   m = u.i[HIGH_HALF];
-  k = 0x7fffffff&m;
+  k = 0x7fffffff & m;
   /*-------------------  |x|<2.77556*10^-17 ----------------------*/
-  if (k < 0x3c880000) return hp0.x;
+  if (k < 0x3c880000)
+    return hp0.x;
 
   /*-----------------  2.77556*10^-17 <= |x| < 2^-3 --------------*/
-  else
-  if (k < 0x3fc00000) {
-    x2 = x*x;
-    t = (((((f6*x2 + f5)*x2 + f4)*x2 + f3)*x2 + f2)*x2 + f1)*(x2*x);
-    r=hp0.x-x;
-    cor=(((hp0.x-r)-x)+hp1.x)-t;
-    res = r+cor;
-    cor = (r-res)+cor;
-    if (res == res+1.004*cor) return res;
-    else {
-      x1 = x+big;
-      xx = x*x;
-      x1 -= big;
-      x2 = x - x1;
-      p = x1*x1*x1;
-      s1 = a1.x*p;
-      s2 = ((((((c7*xx + c6)*xx + c5)*xx + c4)*xx + c3)*xx + c2)*xx*xx*x +
-	    ((a1.x+a2.x)*x2*x2+ 0.5*x1*x)*x2) + a2.x*p;
-      res1 = x+s1;
-      s2 = ((x-res1)+s1)+s2;
-      r=hp0.x-res1;
-      cor=(((hp0.x-r)-res1)+hp1.x)-s2;
-      res = r+cor;
-      cor = (r-res)+cor;
-      if (res == res+1.00004*cor) return res;
-      else {
-	__doasin(x,0,w);
-	r=hp0.x-w[0];
-	cor=((hp0.x-r)-w[0])+(hp1.x-w[1]);
-	res=r+cor;
-	cor=(r-res)+cor;
-	if (res ==(res +1.00000001*cor)) return res;
-	else {
-	  res1=res+1.1*cor;
-	  return __cos32(x,res,res1);
-	}
-      }
-    }
-  }    /*   else  if (k < 0x3fc00000)    */
+  else if (k < 0x3fc00000)
+    {
+      x2 = x * x;
+      t =
+	(((((f6 * x2 + f5) * x2 + f4) * x2 + f3) * x2 + f2) * x2 +
+	 f1) * (x2 * x);
+      r = hp0.x - x;
+      cor = (((hp0.x - r) - x) + hp1.x) - t;
+      res = r + cor;
+      cor = (r - res) + cor;
+      if (res == res + 1.004 * cor)
+      {
+	  LIBC_PROBE (acos_probe, 2, 1, &x);
+	return res;
+	}
+      else
+	{
+	  x1 = x + big;
+	  xx = x * x;
+	  x1 -= big;
+	  x2 = x - x1;
+	  p = x1 * x1 * x1;
+	  s1 = a1.x * p;
+	  s2 =
+	    ((((((c7 * xx + c6) * xx + c5) * xx + c4) * xx + c3) * xx +
+	      c2) * xx * xx * x + ((a1.x + a2.x) * x2 * x2 +
+				   0.5 * x1 * x) * x2) + a2.x * p;
+	  res1 = x + s1;
+	  s2 = ((x - res1) + s1) + s2;
+	  r = hp0.x - res1;
+	  cor = (((hp0.x - r) - res1) + hp1.x) - s2;
+	  res = r + cor;
+	  cor = (r - res) + cor;
+	  if (res == res + 1.00004 * cor)
+	  {
+	  LIBC_PROBE (acos_probe, 2, 2, &x);
+	    return res;
+	    }
+	  else
+	    {
+	      __doasin (x, 0, w);
+	      r = hp0.x - w[0];
+	      cor = ((hp0.x - r) - w[0]) + (hp1.x - w[1]);
+	      res = r + cor;
+	      cor = (r - res) + cor;
+	      if (res == (res + 1.00000001 * cor))
+	      {
+	  LIBC_PROBE (acos_probe, 2, 3, &x);
+		return res;
+		}
+	      else
+		{
+		  res1 = res + 1.1 * cor;
+		  return __cos32 (x, res, res1);
+		}
+	    }
+	}
+    }				/*   else  if (k < 0x3fc00000)    */
   /*----------------------  0.125 <= |x| < 0.5 --------------------*/
-  else
-  if (k < 0x3fe00000) {
-    if (k<0x3fd00000) n = 11*((k&0x000fffff)>>15);
-    else n = 11*((k&0x000fffff)>>14)+352;
-    if (m>0) xx = x - asncs.x[n];
-    else xx = -x - asncs.x[n];
-    t = asncs.x[n+1]*xx;
-    p=xx*xx*(asncs.x[n+2]+xx*(asncs.x[n+3]+xx*(asncs.x[n+4]+
-		   xx*(asncs.x[n+5]+xx*asncs.x[n+6]))))+asncs.x[n+7];
-    t+=p;
-    y = (m>0)?(hp0.x-asncs.x[n+8]):(hp0.x+asncs.x[n+8]);
-    t = (m>0)?(hp1.x-t):(hp1.x+t);
-    res = y+t;
-    if (res == res+1.02*((y-res)+t)) return res;
-    else {
-      r=asncs.x[n+8]+xx*asncs.x[n+9];
-      t=((asncs.x[n+8]-r)+xx*asncs.x[n+9])+(p+xx*asncs.x[n+10]);
-      if (m>0)
-	{p = hp0.x-r; t = (((hp0.x-p)-r)-t)+hp1.x; }
+  else if (k < 0x3fe00000)
+    {
+      if (k < 0x3fd00000)
+	n = 11 * ((k & 0x000fffff) >> 15);
       else
-	{p = hp0.x+r; t = ((hp0.x-p)+r)+(hp1.x+t); }
-      res = p+t;
-      cor = (p-res)+t;
-      if (res == (res+1.0002*cor)) return res;
-      else {
-	res1=res+1.1*cor;
-	z=0.5*(res1-res);
-	__docos(res,z,w);
-	z=(w[0]-x)+w[1];
-	if (z>1.0e-27) return max(res,res1);
-	else if (z<-1.0e-27) return min(res,res1);
-	else return __cos32(x,res,res1);
-      }
-    }
-  }    /*   else  if (k < 0x3fe00000)    */
+	n = 11 * ((k & 0x000fffff) >> 14) + 352;
+      if (m > 0)
+	xx = x - asncs.x[n];
+      else
+	xx = -x - asncs.x[n];
+      t = asncs.x[n + 1] * xx;
+      p =
+	xx * xx * (asncs.x[n + 2] +
+		   xx * (asncs.x[n + 3] +
+			 xx * (asncs.x[n + 4] +
+			       xx * (asncs.x[n + 5] +
+				     xx * asncs.x[n + 6])))) + asncs.x[n + 7];
+      t += p;
+      y = (m > 0) ? (hp0.x - asncs.x[n + 8]) : (hp0.x + asncs.x[n + 8]);
+      t = (m > 0) ? (hp1.x - t) : (hp1.x + t);
+      res = y + t;
+      if (res == res + 1.02 * ((y - res) + t))
+      {
+	  LIBC_PROBE (acos_probe, 2, 4, &x);
+	return res;
+	}
+      else
+	{
+	  r = asncs.x[n + 8] + xx * asncs.x[n + 9];
+	  t =
+	    ((asncs.x[n + 8] - r) + xx * asncs.x[n + 9]) + (p +
+							    xx * asncs.x[n +
+									 10]);
+	  if (m > 0)
+	    {
+	      p = hp0.x - r;
+	      t = (((hp0.x - p) - r) - t) + hp1.x;
+	    }
+	  else
+	    {
+	      p = hp0.x + r;
+	      t = ((hp0.x - p) + r) + (hp1.x + t);
+	    }
+	  res = p + t;
+	  cor = (p - res) + t;
+	  if (res == (res + 1.0002 * cor))
+	  {
+	  LIBC_PROBE (acos_probe, 2, 5, &x);
+	    return res;
+	    }
+	  else
+	    {
+	      res1 = res + 1.1 * cor;
+	      z = 0.5 * (res1 - res);
+	      __docos (res, z, w);
+	      z = (w[0] - x) + w[1];
+	      if (z > 1.0e-27)
+	      {
+	  LIBC_PROBE (acos_probe, 2, 6, &x);
+		return max (res, res1);
+		}
+	      else if (z < -1.0e-27)
+	      {
+	  LIBC_PROBE (acos_probe, 2, 7, &x);
+		return min (res, res1);
+		}
+	      else
+		return __cos32 (x, res, res1);
+	    }
+	}
+    }				/*   else  if (k < 0x3fe00000)    */
 
   /*--------------------------- 0.5 <= |x| < 0.75 ---------------------*/
-  else
-  if (k < 0x3fe80000) {
-    n = 1056+((k&0x000fe000)>>11)*3;
-    if (m>0) {xx = x - asncs.x[n]; eps=1.04; }
-    else {xx = -x - asncs.x[n]; eps=1.02; }
-    t = asncs.x[n+1]*xx;
-    p=xx*xx*(asncs.x[n+2]+xx*(asncs.x[n+3]+xx*(asncs.x[n+4]+
-		   xx*(asncs.x[n+5]+xx*(asncs.x[n+6]+
-		   xx*asncs.x[n+7])))))+asncs.x[n+8];
-    t+=p;
-   y = (m>0)?(hp0.x-asncs.x[n+9]):(hp0.x+asncs.x[n+9]);
-   t = (m>0)?(hp1.x-t):(hp1.x+t);
-   res = y+t;
-   if (res == res+eps*((y-res)+t)) return res;
-   else {
-     r=asncs.x[n+9]+xx*asncs.x[n+10];
-     t=((asncs.x[n+9]-r)+xx*asncs.x[n+10])+(p+xx*asncs.x[n+11]);
-     if (m>0) {p = hp0.x-r; t = (((hp0.x-p)-r)-t)+hp1.x; eps=1.0004; }
-     else   {p = hp0.x+r; t = ((hp0.x-p)+r)+(hp1.x+t); eps=1.0002; }
-     res = p+t;
-     cor = (p-res)+t;
-     if (res == (res+eps*cor)) return res;
-     else {
-       res1=res+1.1*cor;
-       z=0.5*(res1-res);
-       __docos(res,z,w);
-       z=(w[0]-x)+w[1];
-       if (z>1.0e-27) return max(res,res1);
-       else if (z<-1.0e-27) return min(res,res1);
-       else return __cos32(x,res,res1);
-     }
-   }
-  }    /*   else  if (k < 0x3fe80000)    */
+  else if (k < 0x3fe80000)
+    {
+      n = 1056 + ((k & 0x000fe000) >> 11) * 3;
+      if (m > 0)
+	{
+	  xx = x - asncs.x[n];
+	  eps = 1.04;
+	}
+      else
+	{
+	  xx = -x - asncs.x[n];
+	  eps = 1.02;
+	}
+      t = asncs.x[n + 1] * xx;
+      p =
+	xx * xx * (asncs.x[n + 2] +
+		   xx * (asncs.x[n + 3] +
+			 xx * (asncs.x[n + 4] +
+			       xx * (asncs.x[n + 5] +
+				     xx * (asncs.x[n + 6] +
+					   xx * asncs.x[n + 7]))))) +
+	asncs.x[n + 8];
+      t += p;
+      y = (m > 0) ? (hp0.x - asncs.x[n + 9]) : (hp0.x + asncs.x[n + 9]);
+      t = (m > 0) ? (hp1.x - t) : (hp1.x + t);
+      res = y + t;
+      if (res == res + eps * ((y - res) + t))
+	      {
+	  LIBC_PROBE (acos_probe, 2, 8, &x);
+	return res;
+	}
+      else
+	{
+	  r = asncs.x[n + 9] + xx * asncs.x[n + 10];
+	  t =
+	    ((asncs.x[n + 9] - r) + xx * asncs.x[n + 10]) + (p +
+							     xx * asncs.x[n +
+									  11]);
+	  if (m > 0)
+	    {
+	      p = hp0.x - r;
+	      t = (((hp0.x - p) - r) - t) + hp1.x;
+	      eps = 1.0004;
+	    }
+	  else
+	    {
+	      p = hp0.x + r;
+	      t = ((hp0.x - p) + r) + (hp1.x + t);
+	      eps = 1.0002;
+	    }
+	  res = p + t;
+	  cor = (p - res) + t;
+	  if (res == (res + eps * cor))
+	      {
+	  LIBC_PROBE (acos_probe, 2, 9, &x);
+	    return res;
+	    }
+	  else
+	    {
+	      res1 = res + 1.1 * cor;
+	      z = 0.5 * (res1 - res);
+	      __docos (res, z, w);
+	      z = (w[0] - x) + w[1];
+	      if (z > 1.0e-27)
+	      {
+	  LIBC_PROBE (acos_probe, 2, 10, &x);
+		return max (res, res1);
+		}
+	      else if (z < -1.0e-27)
+	      {
+	  LIBC_PROBE (acos_probe, 2, 11, &x);
+		return min (res, res1);
+		}
+	      else
+		return __cos32 (x, res, res1);
+	    }
+	}
+    }				/*   else  if (k < 0x3fe80000)    */
 
 /*------------------------- 0.75 <= |x| < 0.921875 -------------*/
-  else
-  if (k < 0x3fed8000) {
-    n = 992+((k&0x000fe000)>>13)*13;
-    if (m>0) {xx = x - asncs.x[n]; eps = 1.04; }
-    else {xx = -x - asncs.x[n]; eps = 1.01; }
-    t = asncs.x[n+1]*xx;
-    p=xx*xx*(asncs.x[n+2]+xx*(asncs.x[n+3]+xx*(asncs.x[n+4]+
-		      xx*(asncs.x[n+5]+xx*(asncs.x[n+6]+xx*(asncs.x[n+7]+
-		      xx*asncs.x[n+8]))))))+asncs.x[n+9];
-    t+=p;
-    y = (m>0)?(hp0.x-asncs.x[n+10]):(hp0.x+asncs.x[n+10]);
-    t = (m>0)?(hp1.x-t):(hp1.x+t);
-    res = y+t;
-    if (res == res+eps*((y-res)+t)) return res;
-    else {
-      r=asncs.x[n+10]+xx*asncs.x[n+11];
-      t=((asncs.x[n+10]-r)+xx*asncs.x[n+11])+(p+xx*asncs.x[n+12]);
-      if (m>0) {p = hp0.x-r; t = (((hp0.x-p)-r)-t)+hp1.x; eps=1.0032; }
-      else   {p = hp0.x+r; t = ((hp0.x-p)+r)+(hp1.x+t); eps=1.0008; }
-      res = p+t;
-      cor = (p-res)+t;
-      if (res == (res+eps*cor)) return res;
-      else {
-	res1=res+1.1*cor;
-	z=0.5*(res1-res);
-	__docos(res,z,w);
-	z=(w[0]-x)+w[1];
-	if (z>1.0e-27) return max(res,res1);
-	else if (z<-1.0e-27) return min(res,res1);
-	else return __cos32(x,res,res1);
-      }
-    }
-  }    /*   else  if (k < 0x3fed8000)    */
+  else if (k < 0x3fed8000)
+    {
+      n = 992 + ((k & 0x000fe000) >> 13) * 13;
+      if (m > 0)
+	{
+	  xx = x - asncs.x[n];
+	  eps = 1.04;
+	}
+      else
+	{
+	  xx = -x - asncs.x[n];
+	  eps = 1.01;
+	}
+      t = asncs.x[n + 1] * xx;
+      p =
+	xx * xx * (asncs.x[n + 2] +
+		   xx * (asncs.x[n + 3] +
+			 xx * (asncs.x[n + 4] +
+			       xx * (asncs.x[n + 5] +
+				     xx * (asncs.x[n + 6] +
+					   xx * (asncs.x[n + 7] +
+						 xx * asncs.x[n + 8])))))) +
+	asncs.x[n + 9];
+      t += p;
+      y = (m > 0) ? (hp0.x - asncs.x[n + 10]) : (hp0.x + asncs.x[n + 10]);
+      t = (m > 0) ? (hp1.x - t) : (hp1.x + t);
+      res = y + t;
+      if (res == res + eps * ((y - res) + t))
+	      {
+	  LIBC_PROBE (acos_probe, 2, 12, &x);
+	return res;
+	}
+      else
+	{
+	  r = asncs.x[n + 10] + xx * asncs.x[n + 11];
+	  t =
+	    ((asncs.x[n + 10] - r) + xx * asncs.x[n + 11]) + (p +
+							      xx * asncs.x[n +
+									   12]);
+	  if (m > 0)
+	    {
+	      p = hp0.x - r;
+	      t = (((hp0.x - p) - r) - t) + hp1.x;
+	      eps = 1.0032;
+	    }
+	  else
+	    {
+	      p = hp0.x + r;
+	      t = ((hp0.x - p) + r) + (hp1.x + t);
+	      eps = 1.0008;
+	    }
+	  res = p + t;
+	  cor = (p - res) + t;
+	  if (res == (res + eps * cor))
+	      {
+	  LIBC_PROBE (acos_probe, 2, 13, &x);
+	    return res;
+	    }
+	  else
+	    {
+	      res1 = res + 1.1 * cor;
+	      z = 0.5 * (res1 - res);
+	      __docos (res, z, w);
+	      z = (w[0] - x) + w[1];
+	      if (z > 1.0e-27)
+	      {
+	  LIBC_PROBE (acos_probe, 2, 14, &x);
+		return max (res, res1);
+		}
+	      else if (z < -1.0e-27)
+	      {
+	  LIBC_PROBE (acos_probe, 2, 15, &x);
+		return min (res, res1);
+		}
+	      else
+		return __cos32 (x, res, res1);
+	    }
+	}
+    }				/*   else  if (k < 0x3fed8000)    */
 
 /*-------------------0.921875 <= |x| < 0.953125 ------------------*/
-  else
-  if (k < 0x3fee8000) {
-    n = 884+((k&0x000fe000)>>13)*14;
-    if (m>0) {xx = x - asncs.x[n]; eps=1.04; }
-    else {xx = -x - asncs.x[n]; eps =1.005; }
-    t = asncs.x[n+1]*xx;
-    p=xx*xx*(asncs.x[n+2]+xx*(asncs.x[n+3]+xx*(asncs.x[n+4]+
-		   xx*(asncs.x[n+5]+xx*(asncs.x[n+6]
-		   +xx*(asncs.x[n+7]+xx*(asncs.x[n+8]+
-		   xx*asncs.x[n+9])))))))+asncs.x[n+10];
-    t+=p;
-    y = (m>0)?(hp0.x-asncs.x[n+11]):(hp0.x+asncs.x[n+11]);
-    t = (m>0)?(hp1.x-t):(hp1.x+t);
-    res = y+t;
-    if (res == res+eps*((y-res)+t)) return res;
-    else {
-      r=asncs.x[n+11]+xx*asncs.x[n+12];
-      t=((asncs.x[n+11]-r)+xx*asncs.x[n+12])+(p+xx*asncs.x[n+13]);
-      if (m>0) {p = hp0.x-r; t = (((hp0.x-p)-r)-t)+hp1.x; eps=1.0030; }
-      else   {p = hp0.x+r; t = ((hp0.x-p)+r)+(hp1.x+t); eps=1.0005; }
-      res = p+t;
-      cor = (p-res)+t;
-      if (res == (res+eps*cor)) return res;
-      else {
-	res1=res+1.1*cor;
-	z=0.5*(res1-res);
-	__docos(res,z,w);
-	z=(w[0]-x)+w[1];
-	if (z>1.0e-27) return max(res,res1);
-	else if (z<-1.0e-27) return min(res,res1);
-	else return __cos32(x,res,res1);
-      }
-    }
-  }    /*   else  if (k < 0x3fee8000)    */
+  else if (k < 0x3fee8000)
+    {
+      n = 884 + ((k & 0x000fe000) >> 13) * 14;
+      if (m > 0)
+	{
+	  xx = x - asncs.x[n];
+	  eps = 1.04;
+	}
+      else
+	{
+	  xx = -x - asncs.x[n];
+	  eps = 1.005;
+	}
+      t = asncs.x[n + 1] * xx;
+      p =
+	xx * xx * (asncs.x[n + 2] +
+		   xx * (asncs.x[n + 3] +
+			 xx * (asncs.x[n + 4] +
+			       xx * (asncs.x[n + 5] +
+				     xx * (asncs.x[n + 6] +
+					   xx * (asncs.x[n + 7] +
+						 xx * (asncs.x[n + 8] +
+						       xx * asncs.x[n +
+								    9])))))))
+	+ asncs.x[n + 10];
+      t += p;
+      y = (m > 0) ? (hp0.x - asncs.x[n + 11]) : (hp0.x + asncs.x[n + 11]);
+      t = (m > 0) ? (hp1.x - t) : (hp1.x + t);
+      res = y + t;
+      if (res == res + eps * ((y - res) + t))
+	      {
+	  LIBC_PROBE (acos_probe, 2, 16, &x);
+	return res;
+	}
+      else
+	{
+	  r = asncs.x[n + 11] + xx * asncs.x[n + 12];
+	  t =
+	    ((asncs.x[n + 11] - r) + xx * asncs.x[n + 12]) + (p +
+							      xx * asncs.x[n +
+									   13]);
+	  if (m > 0)
+	    {
+	      p = hp0.x - r;
+	      t = (((hp0.x - p) - r) - t) + hp1.x;
+	      eps = 1.0030;
+	    }
+	  else
+	    {
+	      p = hp0.x + r;
+	      t = ((hp0.x - p) + r) + (hp1.x + t);
+	      eps = 1.0005;
+	    }
+	  res = p + t;
+	  cor = (p - res) + t;
+	  if (res == (res + eps * cor))
+	      {
+	  LIBC_PROBE (acos_probe, 2, 17, &x);
+	    return res;
+	    }
+	  else
+	    {
+	      res1 = res + 1.1 * cor;
+	      z = 0.5 * (res1 - res);
+	      __docos (res, z, w);
+	      z = (w[0] - x) + w[1];
+	      if (z > 1.0e-27)
+	      {
+	  LIBC_PROBE (acos_probe, 2, 18, &x);
+		return max (res, res1);
+		}
+	      else if (z < -1.0e-27)
+	      {
+	  LIBC_PROBE (acos_probe, 2, 19, &x);
+		return min (res, res1);
+		}
+	      else
+		return __cos32 (x, res, res1);
+	    }
+	}
+    }				/*   else  if (k < 0x3fee8000)    */
 
   /*--------------------0.953125 <= |x| < 0.96875 ----------------*/
-  else
-  if (k < 0x3fef0000) {
-    n = 768+((k&0x000fe000)>>13)*15;
-    if (m>0) {xx = x - asncs.x[n]; eps=1.04; }
-    else {xx = -x - asncs.x[n]; eps=1.005;}
-    t = asncs.x[n+1]*xx;
-    p=xx*xx*(asncs.x[n+2]+xx*(asncs.x[n+3]+xx*(asncs.x[n+4]+
-	    xx*(asncs.x[n+5]+xx*(asncs.x[n+6]
-	    +xx*(asncs.x[n+7]+xx*(asncs.x[n+8]+xx*(asncs.x[n+9]+
-	    xx*asncs.x[n+10]))))))))+asncs.x[n+11];
-    t+=p;
-    y = (m>0)?(hp0.x-asncs.x[n+12]):(hp0.x+asncs.x[n+12]);
-   t = (m>0)?(hp1.x-t):(hp1.x+t);
-   res = y+t;
-   if (res == res+eps*((y-res)+t)) return res;
-   else {
-     r=asncs.x[n+12]+xx*asncs.x[n+13];
-     t=((asncs.x[n+12]-r)+xx*asncs.x[n+13])+(p+xx*asncs.x[n+14]);
-     if (m>0) {p = hp0.x-r; t = (((hp0.x-p)-r)-t)+hp1.x; eps=1.0030; }
-     else   {p = hp0.x+r; t = ((hp0.x-p)+r)+(hp1.x+t); eps=1.0005; }
-     res = p+t;
-     cor = (p-res)+t;
-     if (res == (res+eps*cor)) return res;
-     else {
-       res1=res+1.1*cor;
-       z=0.5*(res1-res);
-       __docos(res,z,w);
-       z=(w[0]-x)+w[1];
-       if (z>1.0e-27) return max(res,res1);
-       else if (z<-1.0e-27) return min(res,res1);
-       else return __cos32(x,res,res1);
-     }
-   }
-  }    /*   else  if (k < 0x3fef0000)    */
+  else if (k < 0x3fef0000)
+    {
+      n = 768 + ((k & 0x000fe000) >> 13) * 15;
+      if (m > 0)
+	{
+	  xx = x - asncs.x[n];
+	  eps = 1.04;
+	}
+      else
+	{
+	  xx = -x - asncs.x[n];
+	  eps = 1.005;
+	}
+      t = asncs.x[n + 1] * xx;
+      p =
+	xx * xx * (asncs.x[n + 2] +
+		   xx * (asncs.x[n + 3] +
+			 xx * (asncs.x[n + 4] +
+			       xx * (asncs.x[n + 5] +
+				     xx * (asncs.x[n + 6] +
+					   xx * (asncs.x[n + 7] +
+						 xx * (asncs.x[n + 8] +
+						       xx * (asncs.x[n + 9] +
+							     xx * asncs.x[n +
+									  10]))))))))
+	+ asncs.x[n + 11];
+      t += p;
+      y = (m > 0) ? (hp0.x - asncs.x[n + 12]) : (hp0.x + asncs.x[n + 12]);
+      t = (m > 0) ? (hp1.x - t) : (hp1.x + t);
+      res = y + t;
+      if (res == res + eps * ((y - res) + t))
+	      {
+	  LIBC_PROBE (acos_probe, 2, 20, &x);
+	return res;
+	}
+      else
+	{
+	  r = asncs.x[n + 12] + xx * asncs.x[n + 13];
+	  t =
+	    ((asncs.x[n + 12] - r) + xx * asncs.x[n + 13]) + (p +
+							      xx * asncs.x[n +
+									   14]);
+	  if (m > 0)
+	    {
+	      p = hp0.x - r;
+	      t = (((hp0.x - p) - r) - t) + hp1.x;
+	      eps = 1.0030;
+	    }
+	  else
+	    {
+	      p = hp0.x + r;
+	      t = ((hp0.x - p) + r) + (hp1.x + t);
+	      eps = 1.0005;
+	    }
+	  res = p + t;
+	  cor = (p - res) + t;
+	  if (res == (res + eps * cor))
+	      {
+	  LIBC_PROBE (acos_probe, 2, 21, &x);
+	    return res;
+	    }
+	  else
+	    {
+	      res1 = res + 1.1 * cor;
+	      z = 0.5 * (res1 - res);
+	      __docos (res, z, w);
+	      z = (w[0] - x) + w[1];
+	      if (z > 1.0e-27)
+	      {
+	  LIBC_PROBE (acos_probe, 2, 22, &x);
+		return max (res, res1);
+		}
+	      else if (z < -1.0e-27)
+	      {
+	  LIBC_PROBE (acos_probe, 2, 23, &x);
+		return min (res, res1);
+		}
+	      else
+		return __cos32 (x, res, res1);
+	    }
+	}
+    }				/*   else  if (k < 0x3fef0000)    */
   /*-----------------0.96875 <= |x| < 1 ---------------------------*/
 
-  else
-  if (k<0x3ff00000)  {
-    z = 0.5*((m>0)?(1.0-x):(1.0+x));
-    v.x=z;
-    k=v.i[HIGH_HALF];
-    t=inroot[(k&0x001fffff)>>14]*powtwo[511-(k>>21)];
-    r=1.0-t*t*z;
-    t = t*(rt0+r*(rt1+r*(rt2+r*rt3)));
-    c=t*z;
-    t=c*(1.5-0.5*t*c);
-    y = (t27*c+c)-t27*c;
-    cc = (z-y*y)/(t+y);
-    p=(((((f6*z+f5)*z+f4)*z+f3)*z+f2)*z+f1)*z;
-    if (m<0) {
-      cor = (hp1.x - cc)-(y+cc)*p;
-      res1 = hp0.x - y;
-      res =res1 + cor;
-      if (res == res+1.002*((res1-res)+cor)) return (res+res);
-      else {
-	c=y+cc;
-	cc=(y-c)+cc;
-	__doasin(c,cc,w);
-	res1=hp0.x-w[0];
-	cor=((hp0.x-res1)-w[0])+(hp1.x-w[1]);
-	res = res1+cor;
-	cor = (res1-res)+cor;
-	if (res==(res+1.000001*cor)) return (res+res);
-	else {
-	  res=res+res;
-	  res1=res+1.2*cor;
-	  return __cos32(x,res,res1);
-	}
-      }
-    }
-    else {
-      cor = cc+p*(y+cc);
-      res = y + cor;
-      if (res == res+1.03*((y-res)+cor)) return (res+res);
-      else {
-	c=y+cc;
-	cc=(y-c)+cc;
-	__doasin(c,cc,w);
-	res = w[0];
-	cor=w[1];
-	if (res==(res+1.000001*cor)) return (res+res);
-	else {
-	  res=res+res;
-	  res1=res+1.2*cor;
-	  return __cos32(x,res,res1);
-	}
-      }
-    }
-  }    /*   else  if (k < 0x3ff00000)    */
+  else if (k < 0x3ff00000)
+    {
+      z = 0.5 * ((m > 0) ? (1.0 - x) : (1.0 + x));
+      v.x = z;
+      k = v.i[HIGH_HALF];
+      t = inroot[(k & 0x001fffff) >> 14] * powtwo[511 - (k >> 21)];
+      r = 1.0 - t * t * z;
+      t = t * (rt0 + r * (rt1 + r * (rt2 + r * rt3)));
+      c = t * z;
+      t = c * (1.5 - 0.5 * t * c);
+      y = (t27 * c + c) - t27 * c;
+      cc = (z - y * y) / (t + y);
+      p = (((((f6 * z + f5) * z + f4) * z + f3) * z + f2) * z + f1) * z;
+      if (m < 0)
+	{
+	  cor = (hp1.x - cc) - (y + cc) * p;
+	  res1 = hp0.x - y;
+	  res = res1 + cor;
+	  if (res == res + 1.002 * ((res1 - res) + cor))
+	      {
+	  LIBC_PROBE (acos_probe, 2, 24, &x);
+	    return (res + res);
+	    }
+	  else
+	    {
+	      c = y + cc;
+	      cc = (y - c) + cc;
+	      __doasin (c, cc, w);
+	      res1 = hp0.x - w[0];
+	      cor = ((hp0.x - res1) - w[0]) + (hp1.x - w[1]);
+	      res = res1 + cor;
+	      cor = (res1 - res) + cor;
+	      if (res == (res + 1.000001 * cor))
+	      {
+	  LIBC_PROBE (acos_probe, 2, 25, &x);
+		return (res + res);
+		}
+	      else
+		{
+		  res = res + res;
+		  res1 = res + 1.2 * cor;
+		  return __cos32 (x, res, res1);
+		}
+	    }
+	}
+      else
+	{
+	  cor = cc + p * (y + cc);
+	  res = y + cor;
+	  if (res == res + 1.03 * ((y - res) + cor))
+	      {
+	  LIBC_PROBE (acos_probe, 2, 26, &x);
+	    return (res + res);
+	    }
+	  else
+	    {
+	      c = y + cc;
+	      cc = (y - c) + cc;
+	      __doasin (c, cc, w);
+	      res = w[0];
+	      cor = w[1];
+	      if (res == (res + 1.000001 * cor))
+	      {
+	  LIBC_PROBE (acos_probe, 2, 27, &x);
+		return (res + res);
+		}
+	      else
+		{
+		  res = res + res;
+		  res1 = res + 1.2 * cor;
+		  return __cos32 (x, res, res1);
+		}
+	    }
+	}
+    }				/*   else  if (k < 0x3ff00000)    */
 
   /*---------------------------- |x|>=1 -----------------------*/
+  else if (k == 0x3ff00000 && u.i[LOW_HALF] == 0)
+    return (m > 0) ? 0 : 2.0 * hp0.x;
+  else if (k > 0x7ff00000 || (k == 0x7ff00000 && u.i[LOW_HALF] != 0))
+    return x;
   else
-  if (k==0x3ff00000 && u.i[LOW_HALF]==0) return (m>0)?0:2.0*hp0.x;
-  else
-  if (k>0x7ff00000 || (k == 0x7ff00000 && u.i[LOW_HALF] != 0)) return x;
-  else {
-    u.i[HIGH_HALF]=0x7ff00000;
-    v.i[HIGH_HALF]=0x7ff00000;
-    u.i[LOW_HALF]=0;
-    v.i[LOW_HALF]=0;
-    return u.x/v.x;
-  }
+    {
+      u.i[HIGH_HALF] = 0x7ff00000;
+      v.i[HIGH_HALF] = 0x7ff00000;
+      u.i[LOW_HALF] = 0;
+      v.i[LOW_HALF] = 0;
+      return u.x / v.x;
+    }
 }
+
 #ifndef __ieee754_acos
 strong_alias (__ieee754_acos, __acos_finite)
 #endif
diff --git a/sysdeps/ieee754/dbl-64/e_atanh.c b/sysdeps/ieee754/dbl-64/e_atanh.c
index 0f96743..0cb5c34 100644
--- a/sysdeps/ieee754/dbl-64/e_atanh.c
+++ b/sysdeps/ieee754/dbl-64/e_atanh.c
@@ -38,6 +38,7 @@
 #include <inttypes.h>
 #include <math.h>
 #include <math_private.h>
+#include <stap-probe.h>
 
 static const double huge = 1e300;
 
@@ -56,9 +57,13 @@ __ieee754_atanh (double x)
 
       t = xa + xa;
       t = 0.5 * __log1p (t + t * xa / (1.0 - xa));
+      LIBC_PROBE (atanh_probe, 2, 1, &x);
     }
   else if (__glibc_likely (isless (xa, 1.0)))
+  {
+    LIBC_PROBE (atanh_probe, 2, 2, &x);
     t = 0.5 * __log1p ((xa + xa) / (1.0 - xa));
+    }
   else
     {
       if (isgreater (xa, 1.0))
diff --git a/sysdeps/ieee754/dbl-64/e_cosh.c b/sysdeps/ieee754/dbl-64/e_cosh.c
index 6caf943..798591d 100644
--- a/sysdeps/ieee754/dbl-64/e_cosh.c
+++ b/sysdeps/ieee754/dbl-64/e_cosh.c
@@ -33,6 +33,7 @@
 
 #include <math.h>
 #include <math_private.h>
+#include <stap-probe.h>
 
 static const double one = 1.0, half = 0.5, huge = 1.0e300;
 
@@ -55,11 +56,13 @@ __ieee754_cosh (double x)
 	{
 	  t = __expm1 (fabs (x));
 	  w = one + t;
+	  LIBC_PROBE (cosh_probe, 2, 1, &x);
 	  if (ix < 0x3c800000)
 	    return w;                                   /* cosh(tiny) = 1 */
 	  return one + (t * t) / (w + w);
 	}
 
+	  LIBC_PROBE (cosh_probe, 2, 2, &x);
       /* |x| in [0.5*ln2,22], return (exp(|x|)+1/exp(|x|)/2; */
       t = __ieee754_exp (fabs (x));
       return half * t + half / t;
@@ -67,7 +70,10 @@ __ieee754_cosh (double x)
 
   /* |x| in [22, log(maxdouble)] return half*exp(|x|) */
   if (ix < 0x40862e42)
+  {
+	  LIBC_PROBE (cosh_probe, 2, 3, &x);
     return half * __ieee754_exp (fabs (x));
+    }
 
   /* |x| in [log(maxdouble), overflowthresold] */
   GET_LOW_WORD (lx, x);
@@ -75,6 +81,7 @@ __ieee754_cosh (double x)
     {
       w = __ieee754_exp (half * fabs (x));
       t = half * w;
+	  LIBC_PROBE (cosh_probe, 2, 4, &x);
       return t * w;
     }
 
diff --git a/sysdeps/ieee754/dbl-64/e_pow.c b/sysdeps/ieee754/dbl-64/e_pow.c
index 1c5f4b3..4664f7d 100644
--- a/sysdeps/ieee754/dbl-64/e_pow.c
+++ b/sysdeps/ieee754/dbl-64/e_pow.c
@@ -42,6 +42,7 @@
 #include "upow.tbl"
 #include <math_private.h>
 #include <fenv.h>
+#include <stap-probe.h>
 
 #ifndef SECTION
 # define SECTION
@@ -65,6 +66,7 @@ __ieee754_pow (double x, double y)
   double z, a, aa, error, t, a1, a2, y1, y2;
   mynumber u, v;
   int k;
+  int retcode = -1;
   int4 qx, qy;
   v.x = y;
   u.x = x;
@@ -110,7 +112,16 @@ __ieee754_pow (double x, double y)
       a2 = (a - a1) + aa;
       error = error * ABS (y);
       t = __exp1 (a1, a2, 1.9e16 * error);	/* return -10 or 0 if wasn't computed exactly */
-      retval = (t > 0) ? t : power1 (x, y);
+      if (t > 0)
+        {
+	  retval = t;
+      retcode = 1;
+      LIBC_PROBE (pow_probe, 3, &x, &y, &retcode);
+	}
+      else
+        {
+	  retval = power1 (x, y);
+	}
 
       return retval;
     }
@@ -140,6 +151,8 @@ __ieee754_pow (double x, double y)
   /* if x<0 */
   if (u.i[HIGH_HALF] < 0)
     {
+      retcode = 2;
+      LIBC_PROBE (pow_probe, 3, &x, &y, &retcode);
       k = checkint (y);
       if (k == 0)
 	{
@@ -199,6 +212,7 @@ static double
 SECTION
 power1 (double x, double y)
 {
+  int retcode = 3;
   double z, a, aa, error, t, a1, a2, y1, y2;
   z = my_log2 (x, &aa, &error);
   t = y * CN;
@@ -213,7 +227,13 @@ power1 (double x, double y)
   a2 = (a - a1) + aa;
   error = error * ABS (y);
   t = __exp1 (a1, a2, 1.9e16 * error);
-  return (t >= 0) ? t : __slowpow (x, y, z);
+  if (t >= 0)
+    {
+      LIBC_PROBE (pow_probe, 3, &x, &y, &retcode);
+      return t;
+    }
+  else
+    return __slowpow (x, y, z);
 }
 
 /* Compute log(x) (x is left argument). The result is the returned double + the
diff --git a/sysdeps/ieee754/dbl-64/e_sinh.c b/sysdeps/ieee754/dbl-64/e_sinh.c
index 4ff28bf..3482edf 100644
--- a/sysdeps/ieee754/dbl-64/e_sinh.c
+++ b/sysdeps/ieee754/dbl-64/e_sinh.c
@@ -34,6 +34,7 @@ static char rcsid[] = "$NetBSD: e_sinh.c,v 1.7 1995/05/10 20:46:13 jtc Exp $";
 
 #include <math.h>
 #include <math_private.h>
+#include <stap-probe.h>
 
 static const double one = 1.0, shuge = 1.0e307;
 
@@ -63,6 +64,7 @@ __ieee754_sinh (double x)
 	  return x;
       /* sinh(tiny) = tiny with inexact */
       t = __expm1 (fabs (x));
+	  LIBC_PROBE (sinh_probe, 2, 1, &x);
       if (ix < 0x3ff00000)
 	return h * (2.0 * t - t * t / (t + one));
       return h * (t + t / (t + one));
@@ -70,12 +72,16 @@ __ieee754_sinh (double x)
 
   /* |x| in [22, log(maxdouble)] return 0.5*exp(|x|) */
   if (ix < 0x40862e42)
+  {
+	  LIBC_PROBE (sinh_probe, 2, 2, &x);
     return h * __ieee754_exp (fabs (x));
+    }
 
   /* |x| in [log(maxdouble), overflowthresold] */
   GET_LOW_WORD (lx, x);
   if (ix < 0x408633ce || ((ix == 0x408633ce) && (lx <= (u_int32_t) 0x8fb9f87d)))
     {
+	  LIBC_PROBE (sinh_probe, 2, 3, &x);
       w = __ieee754_exp (0.5 * fabs (x));
       t = h * w;
       return t * w;
diff --git a/sysdeps/ieee754/dbl-64/s_asinh.c b/sysdeps/ieee754/dbl-64/s_asinh.c
index a33758d..b6e7d95 100644
--- a/sysdeps/ieee754/dbl-64/s_asinh.c
+++ b/sysdeps/ieee754/dbl-64/s_asinh.c
@@ -23,6 +23,7 @@
 
 #include <math.h>
 #include <math_private.h>
+#include <stap-probe.h>
 
 static const double
   one = 1.00000000000000000000e+00, /* 0x3FF00000, 0x00000000 */
@@ -46,6 +47,7 @@ __asinh (double x)
       if (ix >= 0x7ff00000)
 	return x + x;                           /* x is inf or NaN */
       w = __ieee754_log (fabs (x)) + ln2;
+      LIBC_PROBE (asinh_probe, 2, 1, &x);
     }
   else
     {
@@ -54,11 +56,13 @@ __asinh (double x)
 	{
 	  w = __ieee754_log (2.0 * xa + one / (__ieee754_sqrt (xa * xa + one) +
               xa));
+	  LIBC_PROBE (asinh_probe, 2, 2, &x);
 	}
       else                      /* 2.0 > |x| > 2**-28 */
 	{
 	  double t = xa * xa;
 	  w = __log1p (xa + t / (one + __ieee754_sqrt (one + t)));
+	  LIBC_PROBE (asinh_probe, 2, 3, &x);
 	}
     }
   return __copysign (w, x);
diff --git a/sysdeps/ieee754/dbl-64/s_atan.c b/sysdeps/ieee754/dbl-64/s_atan.c
index 0aa145c..456ffea 100644
--- a/sysdeps/ieee754/dbl-64/s_atan.c
+++ b/sysdeps/ieee754/dbl-64/s_atan.c
@@ -97,7 +97,10 @@ atan (double x)
 	      yy *= x * v;
 
 	      if ((y = x + (yy - U1 * x)) == x + (yy + U1 * x))
+	      {
+	        LIBC_PROBE (atan_probe, 2, 1, &x);
 		return y;
+		}
 
 	      EMULV (x, x, v, vv, t1, t2, t3, t4, t5);	/* v+vv=x^2 */
 
@@ -119,7 +122,10 @@ atan (double x)
 		    t8);
 	      ADD2 (x, 0, s2, ss2, s1, ss1, t1, t2);
 	      if ((y = s1 + (ss1 - U5 * s1)) == s1 + (ss1 + U5 * s1))
+	      {
+	        LIBC_PROBE (atan_probe, 2, 2, &x);
 		return y;
+		}
 
 	      return atanMp (x, pr);
 	    }
@@ -151,7 +157,10 @@ atan (double x)
 		u2 = U24;
 	    }			/* 3/4 <= u <= 1  */
 	  if ((y = t1 + (yy - u2 * t1)) == t1 + (yy + u2 * t1))
+	  {
+	        LIBC_PROBE (atan_probe, 2, 3, &x);
 	    return __signArctan (x, y);
+	    }
 
 	  z = u - hij[i][0].d;
 
@@ -171,7 +180,10 @@ atan (double x)
 	  MUL2 (z, 0, s2, ss2, s1, ss1, t1, t2, t3, t4, t5, t6, t7, t8);
 	  ADD2 (hij[i][1].d, hij[i][2].d, s1, ss1, s2, ss2, t1, t2);
 	  if ((y = s2 + (ss2 - U6 * s2)) == s2 + (ss2 + U6 * s2))
+	  {
+	        LIBC_PROBE (atan_probe, 2, 4, &x);
 	    return __signArctan (x, y);
+	    }
 
 	  return atanMp (x, pr);
 	}
@@ -199,7 +211,10 @@ atan (double x)
 	  else
 	    u3 = U32;           /* w >= 1/2 */
 	  if ((y = t1 + (yy - u3)) == t1 + (yy + u3))
+	  {
+	        LIBC_PROBE (atan_probe, 2, 5, &x);
 	    return __signArctan (x, y);
+	    }
 
 	  DIV2 (1, 0, u, 0, w, ww, t1, t2, t3, t4, t5, t6, t7, t8, t9,
 		t10);
@@ -223,7 +238,10 @@ atan (double x)
 	  ADD2 (hij[i][1].d, hij[i][2].d, s1, ss1, s2, ss2, t1, t2);
 	  SUB2 (HPI, HPI1, s2, ss2, s1, ss1, t1, t2);
 	  if ((y = s1 + (ss1 - U7)) == s1 + (ss1 + U7))
+	  {
+	        LIBC_PROBE (atan_probe, 2, 6, &x);
 	    return __signArctan (x, y);
+	    }
 
 	  return atanMp (x, pr);
 	}
@@ -246,7 +264,10 @@ atan (double x)
 	      ESUB (HPI, w, t3, cor);
 	      yy = ((HPI1 + cor) - ww) - yy;
 	      if ((y = t3 + (yy - U4)) == t3 + (yy + U4))
+	      {
+	        LIBC_PROBE (atan_probe, 2, 7, &x);
 		return __signArctan (x, y);
+		}
 
 	      DIV2 (1, 0, u, 0, w, ww, t1, t2, t3, t4, t5, t6, t7, t8,
 		    t9, t10);
@@ -271,7 +292,10 @@ atan (double x)
 	      SUB2 (HPI, HPI1, s1, ss1, s2, ss2, t1, t2);
 
 	      if ((y = s2 + (ss2 - U8)) == s2 + (ss2 + U8))
+	      {
+	        LIBC_PROBE (atan_probe, 2, 8, &x);
 		return __signArctan (x, y);
+		}
 
 	      return atanMp (x, pr);
 	    }
diff --git a/sysdeps/ieee754/dbl-64/s_sin.c b/sysdeps/ieee754/dbl-64/s_sin.c
index 50109b8..65ba953 100644
--- a/sysdeps/ieee754/dbl-64/s_sin.c
+++ b/sysdeps/ieee754/dbl-64/s_sin.c
@@ -303,7 +303,7 @@ __sin (double x)
       t = POLYNOMIAL (xx) * (xx * x);
       res = x + t;
       cor = (x - res) + t;
-      retval = (res == res + 1.07 * cor) ? res : slow (x);
+      if (res == res + 1.07 * cor) { LIBC_PROBE (sin_probe, 2, 1, &x); retval = res; } else retval = slow (x);
     }				/*  else  if (k < 0x3fd00000)    */
 /*---------------------------- 0.25<|x|< 0.855469---------------------- */
   else if (k < 0x3feb6000)
@@ -322,7 +322,7 @@ __sin (double x)
       cor = (ssn + s * ccs - sn * c) + cs * s;
       res = sn + cor;
       cor = (sn - res) + cor;
-      retval = (res == res + 1.096 * cor) ? res : slow1 (x);
+      if (res == res + 1.096 * cor) { LIBC_PROBE (sin_probe, 2, 2, &x); retval = res; } else retval = slow1 (x);
     }				/*   else  if (k < 0x3feb6000)    */
 
 /*----------------------- 0.855469  <|x|<2.426265  ----------------------*/
@@ -341,7 +341,7 @@ __sin (double x)
 	  y = (-hp1) - (y + (u.x - big));
 	}
       res = do_cos (u, y, &cor);
-      retval = (res == res + 1.020 * cor) ? ((m > 0) ? res : -res) : slow2 (x);
+      if (res == res + 1.020 * cor) { LIBC_PROBE (sin_probe, 2, 3, &x); retval = ((m > 0) ? res : -res); } else retval = slow2 (x);
     }				/*   else  if (k < 0x400368fd)    */
 
 /*-------------------------- 2.426265<|x|< 105414350 ----------------------*/
@@ -372,7 +372,7 @@ __sin (double x)
 	      /* Taylor series.  */
 	      res = TAYLOR_SIN (xx, a, da, cor);
 	      cor = (cor > 0) ? 1.02 * cor + eps : 1.02 * cor - eps;
-	      retval = (res == res + cor) ? res : sloww (a, da, x);
+	      if (res == res + cor) { LIBC_PROBE (sin_probe, 2, 4, &x); retval = res; } else retval = sloww (a, da, x);
 	    }
 	  else
 	    {
@@ -388,8 +388,7 @@ __sin (double x)
 	      y = a - (u.x - big);
 	      res = do_sin (u, y, da, &cor);
 	      cor = (cor > 0) ? 1.035 * cor + eps : 1.035 * cor - eps;
-	      retval = ((res == res + cor) ? ((m) ? res : -res)
-			: sloww1 (a, da, x, m));
+	      if (res == res + cor) { LIBC_PROBE (sin_probe, 2, 5, &x); retval = ((m) ? res : -res); } else retval = sloww1 (a, da, x, m);
 	    }
 	  break;
 
@@ -404,8 +403,7 @@ __sin (double x)
 	  y = a - (u.x - big) + da;
 	  res = do_cos (u, y, &cor);
 	  cor = (cor > 0) ? 1.025 * cor + eps : 1.025 * cor - eps;
-	  retval = ((res == res + cor) ? ((n & 2) ? -res : res)
-		    : sloww2 (a, da, x, n));
+	  if (res == res + cor) { LIBC_PROBE (sin_probe, 2, 6, &x); retval = ((n & 2) ? -res : res); } else retval = sloww2 (a, da, x, n);
 	  break;
 	}
     }				/*   else  if (k <  0x419921FB )    */
@@ -443,7 +441,7 @@ __sin (double x)
 	      /* Taylor series.  */
 	      res = TAYLOR_SIN (xx, a, da, cor);
 	      cor = (cor > 0) ? 1.02 * cor + eps : 1.02 * cor - eps;
-	      retval = (res == res + cor) ? res : bsloww (a, da, x, n);
+	      if (res == res + cor) { LIBC_PROBE (sin_probe, 2, 7, &x); retval = res; } else retval = bsloww (a, da, x, n);
 	    }
 	  else
 	    {
@@ -464,8 +462,7 @@ __sin (double x)
 	      y = t - (u.x - big);
 	      res = do_sin (u, y, db, &cor);
 	      cor = (cor > 0) ? 1.035 * cor + eps : 1.035 * cor - eps;
-	      retval = ((res == res + cor) ? ((m) ? res : -res)
-			: bsloww1 (a, da, x, n));
+	      if (res == res + cor) { LIBC_PROBE (sin_probe, 2, 8, &x); retval = ((m) ? res : -res); } else retval = bsloww1 (a, da, x, n);
 	    }
 	  break;
 
@@ -480,8 +477,7 @@ __sin (double x)
 	  y = a - (u.x - big) + da;
 	  res = do_cos (u, y, &cor);
 	  cor = (cor > 0) ? 1.025 * cor + eps : 1.025 * cor - eps;
-	  retval = ((res == res + cor) ? ((n & 2) ? -res : res)
-		    : bsloww2 (a, da, x, n));
+	  if (res == res + cor) { LIBC_PROBE (sin_probe, 2, 9, &x); retval = ((n & 2) ? -res : res); } else retval = bsloww2 (a, da, x, n);
 	  break;
 	}
     }				/*   else  if (k <  0x42F00000 )   */
@@ -534,7 +530,7 @@ __cos (double x)
       u.x = big + y;
       y = y - (u.x - big);
       res = do_cos (u, y, &cor);
-      retval = (res == res + 1.020 * cor) ? res : cslow2 (x);
+      if (res == res + 1.020 * cor) { LIBC_PROBE (cos_probe, 2, 1, &x); retval = res; } else retval = cslow2 (x);
     }				/*   else  if (k < 0x3feb6000)    */
 
   else if (k < 0x400368fd)
@@ -547,7 +543,7 @@ __cos (double x)
 	{
 	  res = TAYLOR_SIN (xx, a, da, cor);
 	  cor = (cor > 0) ? 1.02 * cor + 1.0e-31 : 1.02 * cor - 1.0e-31;
-	  retval = (res == res + cor) ? res : csloww (a, da, x);
+	  if (res == res + cor) { LIBC_PROBE (cos_probe, 2, 2, &x); retval = res; } else retval = csloww (a, da, x);
 	}
       else
 	{
@@ -565,8 +561,7 @@ __cos (double x)
 	  y = a - (u.x - big);
 	  res = do_sin (u, y, da, &cor);
 	  cor = (cor > 0) ? 1.035 * cor + 1.0e-31 : 1.035 * cor - 1.0e-31;
-	  retval = ((res == res + cor) ? ((m) ? res : -res)
-		    : csloww1 (a, da, x, m));
+	  if (res == res + cor) { LIBC_PROBE (cos_probe, 2, 3, &x); retval = ((m) ? res : -res); } else retval = csloww1 (a, da, x, m);
 	}
 
     }				/*   else  if (k < 0x400368fd)    */
@@ -598,7 +593,7 @@ __cos (double x)
 	    {
 	      res = TAYLOR_SIN (xx, a, da, cor);
 	      cor = (cor > 0) ? 1.02 * cor + eps : 1.02 * cor - eps;
-	      retval = (res == res + cor) ? res : csloww (a, da, x);
+	      if (res == res + cor) { LIBC_PROBE (cos_probe, 2, 4, &x); retval = res; } else retval = csloww (a, da, x);
 	    }
 	  else
 	    {
@@ -616,8 +611,7 @@ __cos (double x)
 	      y = a - (u.x - big);
 	      res = do_sin (u, y, da, &cor);
 	      cor = (cor > 0) ? 1.035 * cor + eps : 1.035 * cor - eps;
-	      retval = ((res == res + cor) ? ((m) ? res : -res)
-			: csloww1 (a, da, x, m));
+	      if (res == res + cor) { LIBC_PROBE (cos_probe, 2, 5, &x); retval = ((m) ? res : -res); } else retval = csloww1 (a, da, x, m);
 	    }
 	  break;
 
@@ -632,8 +626,7 @@ __cos (double x)
 	  y = a - (u.x - big) + da;
 	  res = do_cos (u, y, &cor);
 	  cor = (cor > 0) ? 1.025 * cor + eps : 1.025 * cor - eps;
-	  retval = ((res == res + cor) ? ((n) ? -res : res)
-		    : csloww2 (a, da, x, n));
+	  if (res == res + cor) { LIBC_PROBE (cos_probe, 2, 6, &x); retval = ((n) ? -res : res); } else retval = csloww2 (a, da, x, n);
 	  break;
 	}
     }				/*   else  if (k <  0x419921FB )    */
@@ -669,7 +662,7 @@ __cos (double x)
 	    {
 	      res = TAYLOR_SIN (xx, a, da, cor);
 	      cor = (cor > 0) ? 1.02 * cor + eps : 1.02 * cor - eps;
-	      retval = (res == res + cor) ? res : bsloww (a, da, x, n);
+	      if (res == res + cor) { LIBC_PROBE (cos_probe, 2, 7, &x); retval = res; } else retval = bsloww (a, da, x, n);
 	    }
 	  else
 	    {
@@ -690,8 +683,7 @@ __cos (double x)
 	      y = t - (u.x - big);
 	      res = do_sin (u, y, db, &cor);
 	      cor = (cor > 0) ? 1.035 * cor + eps : 1.035 * cor - eps;
-	      retval = ((res == res + cor) ? ((m) ? res : -res)
-			: bsloww1 (a, da, x, n));
+	      if (res == res + cor) { LIBC_PROBE (cos_probe, 2, 8, &x); retval = ((m) ? res : -res); } else retval = bsloww1 (a, da, x, n);
 	    }
 	  break;
 
@@ -706,8 +698,7 @@ __cos (double x)
 	  y = a - (u.x - big) + da;
 	  res = do_cos (u, y, &cor);
 	  cor = (cor > 0) ? 1.025 * cor + eps : 1.025 * cor - eps;
-	  retval = ((res == res + cor) ? ((n) ? -res : res)
-		    : bsloww2 (a, da, x, n));
+	  if (res == res + cor) { LIBC_PROBE (cos_probe, 2, 9, &x); retval = ((n) ? -res : res); } else retval = bsloww2 (a, da, x, n);
 	  break;
 	}
     }				/*   else  if (k <  0x42F00000 )    */
@@ -738,12 +729,18 @@ slow (double x)
   double res, cor, w[2];
   res = TAYLOR_SLOW (x, 0, cor);
   if (res == res + 1.0007 * cor)
-    return res;
+    {
+    LIBC_PROBE (sin_probe, 2, 10, &x);
+      return res;
+    }
   else
     {
       __dubsin (ABS (x), 0, w);
       if (w[0] == w[0] + 1.000000001 * w[1])
+        {
+	LIBC_PROBE (sin_probe, 2, 11, &x);
 	return (x > 0) ? w[0] : -w[0];
+	}
       else
 	return (x > 0) ? __mpsin (x, 0, false) : -__mpsin (-x, 0, false);
     }
@@ -765,12 +762,18 @@ slow1 (double x)
   y = y - (u.x - big);
   res = do_sin_slow (u, y, 0, 0, &cor);
   if (res == res + cor)
+  {
+  LIBC_PROBE (sin_probe, 2, 12, &x);
     return (x > 0) ? res : -res;
+    }
   else
     {
       __dubsin (ABS (x), 0, w);
       if (w[0] == w[0] + 1.000000005 * w[1])
+      {
+      LIBC_PROBE (sin_probe, 2, 13, &x);
 	return (x > 0) ? w[0] : -w[0];
+	}
       else
 	return (x > 0) ? __mpsin (x, 0, false) : -__mpsin (-x, 0, false);
     }
@@ -803,7 +806,8 @@ slow2 (double x)
     }
   res = do_cos_slow (u, y, del, 0, &cor);
   if (res == res + cor)
-    return (x > 0) ? res : -res;
+  { LIBC_PROBE (sin_probe, 2, 14, &x);
+    return (x > 0) ? res : -res; }
   else
     {
       y = ABS (x) - hp0;
@@ -811,7 +815,8 @@ slow2 (double x)
       y2 = (y - y1) - hp1;
       __docos (y1, y2, w);
       if (w[0] == w[0] + 1.000000005 * w[1])
-	return (x > 0) ? w[0] : -w[0];
+  { LIBC_PROBE (sin_probe, 2, 15, &x);
+	return (x > 0) ? w[0] : -w[0]; }
       else
 	return (x > 0) ? __mpsin (x, 0, false) : -__mpsin (-x, 0, false);
     }
@@ -839,7 +844,8 @@ sloww (double x, double dx, double orig)
     cor = 1.0005 * cor - ABS (orig) * 3.1e-30;
 
   if (res == res + cor)
-    return res;
+  { LIBC_PROBE (sin_probe, 2, 16, &orig);
+    return res;}
   else
     {
       (x > 0) ? __dubsin (x, dx, w) : __dubsin (-x, -dx, w);
@@ -849,7 +855,8 @@ sloww (double x, double dx, double orig)
 	cor = 1.000000001 * w[1] - ABS (orig) * 1.1e-30;
 
       if (w[0] == w[0] + cor)
-	return (x > 0) ? w[0] : -w[0];
+  { LIBC_PROBE (sin_probe, 2, 17, &orig);
+	return (x > 0) ? w[0] : -w[0]; }
       else
 	{
 	  t = (orig * hpinv + toint);
@@ -875,7 +882,8 @@ sloww (double x, double dx, double orig)
 	    cor = 1.000000001 * w[1] - ABS (orig) * 1.1e-40;
 
 	  if (w[0] == w[0] + cor)
-	    return (a > 0) ? w[0] : -w[0];
+  { LIBC_PROBE (sin_probe, 2, 18, &orig);
+	    return (a > 0) ? w[0] : -w[0]; }
 	  else
 	    return __mpsin (orig, 0, true);
 	}
@@ -901,7 +909,8 @@ sloww1 (double x, double dx, double orig, int m)
   res = do_sin_slow (u, y, dx, 3.1e-30 * ABS (orig), &cor);
 
   if (res == res + cor)
-    return (m > 0) ? res : -res;
+  { LIBC_PROBE (sin_probe, 2, 19, &orig);
+    return (m > 0) ? res : -res; }
   else
     {
       __dubsin (x, dx, w);
@@ -912,7 +921,8 @@ sloww1 (double x, double dx, double orig, int m)
 	cor = 1.000000005 * w[1] - 1.1e-30 * ABS (orig);
 
       if (w[0] == w[0] + cor)
-	return (m > 0) ? w[0] : -w[0];
+  { LIBC_PROBE (sin_probe, 2, 20, &orig);
+	return (m > 0) ? w[0] : -w[0]; }
       else
 	return __mpsin (orig, 0, true);
     }
@@ -937,7 +947,8 @@ sloww2 (double x, double dx, double orig, int n)
   res = do_cos_slow (u, y, dx, 3.1e-30 * ABS (orig), &cor);
 
   if (res == res + cor)
-    return (n & 2) ? -res : res;
+  { LIBC_PROBE (sin_probe, 2, 21, &orig);
+    return (n & 2) ? -res : res; }
   else
     {
       __docos (x, dx, w);
@@ -948,7 +959,8 @@ sloww2 (double x, double dx, double orig, int n)
 	cor = 1.000000005 * w[1] - 1.1e-30 * ABS (orig);
 
       if (w[0] == w[0] + cor)
-	return (n & 2) ? -w[0] : w[0];
+  { LIBC_PROBE (sin_probe, 2, 22, &orig);
+	return (n & 2) ? -w[0] : w[0]; }
       else
 	return __mpsin (orig, 0, true);
     }
@@ -971,7 +983,8 @@ bsloww (double x, double dx, double orig, int n)
   res = TAYLOR_SLOW (x, dx, cor);
   cor = (cor > 0) ? 1.0005 * cor + 1.1e-24 : 1.0005 * cor - 1.1e-24;
   if (res == res + cor)
-    return res;
+  { LIBC_PROBE (sincos_probe, 2, 1, &orig);
+    return res; }
   else
     {
       (x > 0) ? __dubsin (x, dx, w) : __dubsin (-x, -dx, w);
@@ -980,7 +993,8 @@ bsloww (double x, double dx, double orig, int n)
       else
 	cor = 1.000000001 * w[1] - 1.1e-24;
       if (w[0] == w[0] + cor)
-	return (x > 0) ? w[0] : -w[0];
+  { LIBC_PROBE (sincos_probe, 2, 2, &orig);
+	return (x > 0) ? w[0] : -w[0]; }
       else
 	return (n & 1) ? __mpcos (orig, 0, true) : __mpsin (orig, 0, true);
     }
@@ -1006,7 +1020,8 @@ bsloww1 (double x, double dx, double orig, int n)
   dx = (x > 0) ? dx : -dx;
   res = do_sin_slow (u, y, dx, 1.1e-24, &cor);
   if (res == res + cor)
-    return (x > 0) ? res : -res;
+  { LIBC_PROBE (sincos_probe, 2, 3, &orig);
+    return (x > 0) ? res : -res; }
   else
     {
       __dubsin (ABS (x), dx, w);
@@ -1017,7 +1032,8 @@ bsloww1 (double x, double dx, double orig, int n)
 	cor = 1.000000005 * w[1] - 1.1e-24;
 
       if (w[0] == w[0] + cor)
-	return (x > 0) ? w[0] : -w[0];
+  { LIBC_PROBE (sincos_probe, 2, 4, &orig);
+	return (x > 0) ? w[0] : -w[0]; }
       else
 	return (n & 1) ? __mpcos (orig, 0, true) : __mpsin (orig, 0, true);
     }
@@ -1043,7 +1059,8 @@ bsloww2 (double x, double dx, double orig, int n)
   dx = (x > 0) ? dx : -dx;
   res = do_cos_slow (u, y, dx, 1.1e-24, &cor);
   if (res == res + cor)
-    return (n & 2) ? -res : res;
+  { LIBC_PROBE (sincos_probe, 2, 5, &orig);
+    return (n & 2) ? -res : res; }
   else
     {
       __docos (ABS (x), dx, w);
@@ -1054,7 +1071,8 @@ bsloww2 (double x, double dx, double orig, int n)
 	cor = 1.000000005 * w[1] - 1.1e-24;
 
       if (w[0] == w[0] + cor)
-	return (n & 2) ? -w[0] : w[0];
+  { LIBC_PROBE (sincos_probe, 2, 6, &orig);
+	return (n & 2) ? -w[0] : w[0]; }
       else
 	return (n & 1) ? __mpsin (orig, 0, true) : __mpcos (orig, 0, true);
     }
@@ -1077,13 +1095,15 @@ cslow2 (double x)
   y = y - (u.x - big);
   res = do_cos_slow (u, y, 0, 0, &cor);
   if (res == res + cor)
-    return res;
+  { LIBC_PROBE (cos_probe, 2, 10, &x);
+    return res; }
   else
     {
       y = ABS (x);
       __docos (y, 0, w);
       if (w[0] == w[0] + 1.000000005 * w[1])
-	return w[0];
+  { LIBC_PROBE (cos_probe, 2, 11, &x);
+	return w[0]; }
       else
 	return __mpcos (x, 0, false);
     }
@@ -1114,7 +1134,8 @@ csloww (double x, double dx, double orig)
     cor = 1.0005 * cor - ABS (orig) * 3.1e-30;
 
   if (res == res + cor)
-    return res;
+  { LIBC_PROBE (cos_probe, 2, 12, &orig);
+    return res; }
   else
     {
       (x > 0) ? __dubsin (x, dx, w) : __dubsin (-x, -dx, w);
@@ -1125,7 +1146,8 @@ csloww (double x, double dx, double orig)
 	cor = 1.000000001 * w[1] - ABS (orig) * 1.1e-30;
 
       if (w[0] == w[0] + cor)
-	return (x > 0) ? w[0] : -w[0];
+  { LIBC_PROBE (cos_probe, 2, 13, &orig);
+	return (x > 0) ? w[0] : -w[0]; }
       else
 	{
 	  t = (orig * hpinv + toint);
@@ -1152,7 +1174,8 @@ csloww (double x, double dx, double orig)
 	    cor = 1.000000001 * w[1] - ABS (orig) * 1.1e-40;
 
 	  if (w[0] == w[0] + cor)
-	    return (a > 0) ? w[0] : -w[0];
+  { LIBC_PROBE (cos_probe, 2, 14, &orig);
+	    return (a > 0) ? w[0] : -w[0]; }
 	  else
 	    return __mpcos (orig, 0, true);
 	}
@@ -1178,7 +1201,8 @@ csloww1 (double x, double dx, double orig, int m)
   res = do_sin_slow (u, y, dx, 3.1e-30 * ABS (orig), &cor);
 
   if (res == res + cor)
-    return (m > 0) ? res : -res;
+  { LIBC_PROBE (cos_probe, 2, 15, &orig);
+    return (m > 0) ? res : -res; }
   else
     {
       __dubsin (x, dx, w);
@@ -1187,7 +1211,8 @@ csloww1 (double x, double dx, double orig, int m)
       else
 	cor = 1.000000005 * w[1] - 1.1e-30 * ABS (orig);
       if (w[0] == w[0] + cor)
-	return (m > 0) ? w[0] : -w[0];
+  { LIBC_PROBE (cos_probe, 2, 16, &orig);
+	return (m > 0) ? w[0] : -w[0]; }
       else
 	return __mpcos (orig, 0, true);
     }
@@ -1213,7 +1238,8 @@ csloww2 (double x, double dx, double orig, int n)
   res = do_cos_slow (u, y, dx, 3.1e-30 * ABS (orig), &cor);
 
   if (res == res + cor)
-    return (n) ? -res : res;
+  { LIBC_PROBE (cos_probe, 2, 17, &orig);
+    return (n) ? -res : res; }
   else
     {
       __docos (x, dx, w);
@@ -1222,7 +1248,8 @@ csloww2 (double x, double dx, double orig, int n)
       else
 	cor = 1.000000005 * w[1] - 1.1e-30 * ABS (orig);
       if (w[0] == w[0] + cor)
-	return (n) ? -w[0] : w[0];
+  { LIBC_PROBE (cos_probe, 2, 18, &orig);
+	return (n) ? -w[0] : w[0]; }
       else
 	return __mpcos (orig, 0, true);
     }
diff --git a/sysdeps/ieee754/dbl-64/s_tanh.c b/sysdeps/ieee754/dbl-64/s_tanh.c
index 23cfcde..4286a71 100644
--- a/sysdeps/ieee754/dbl-64/s_tanh.c
+++ b/sysdeps/ieee754/dbl-64/s_tanh.c
@@ -40,6 +40,7 @@ static char rcsid[] = "$NetBSD: s_tanh.c,v 1.7 1995/05/10 20:48:22 jtc Exp $";
 
 #include <math.h>
 #include <math_private.h>
+#include <stap-probe.h>
 
 static const double one = 1.0, two = 2.0, tiny = 1.0e-300;
 
@@ -73,11 +74,13 @@ __tanh (double x)
 	{
 	  t = __expm1 (two * fabs (x));
 	  z = one - two / (t + two);
+	  LIBC_PROBE (tanh_probe, 2, 1, &x);
 	}
       else
 	{
 	  t = __expm1 (-two * fabs (x));
 	  z = -t / (t + two);
+	  LIBC_PROBE (tanh_probe, 2, 2, &x);
 	}
       /* |x| > 22, return +-1 */
     }
diff --git a/sysdeps/ieee754/dbl-64/wordsize-64/e_acosh.c b/sysdeps/ieee754/dbl-64/wordsize-64/e_acosh.c
index ccccdaf..586de12 100644
--- a/sysdeps/ieee754/dbl-64/wordsize-64/e_acosh.c
+++ b/sysdeps/ieee754/dbl-64/wordsize-64/e_acosh.c
@@ -26,6 +26,7 @@
 
 #include <math.h>
 #include <math_private.h>
+#include <stap-probe.h>
 
 static const double
 one	= 1.0,
@@ -46,17 +47,22 @@ __ieee754_acosh (double x)
 	    /* x is inf of NaN */
 	    return x + x;
 	  else
+	  {
+	    LIBC_PROBE (acosh_probe, 2, 1, &x);
 	    return __ieee754_log (x) + ln2;/* acosh(huge)=log(2x) */
+	    }
 	}
 
       /* 2**28 > x > 2 */
       double t = x * x;
+	    LIBC_PROBE (acosh_probe, 2, 2, &x);
       return __ieee754_log (2.0 * x - one / (x + __ieee754_sqrt (t - one)));
     }
   else if (__glibc_likely (hx > INT64_C (0x3ff0000000000000)))
     {
       /* 1<x<2 */
       double t = x - one;
+	    LIBC_PROBE (acosh_probe, 2, 3, &x);
       return __log1p (t + __ieee754_sqrt (2.0 * t + t * t));
     }
   else if (__glibc_likely (hx == INT64_C (0x3ff0000000000000)))
diff --git a/sysdeps/ieee754/dbl-64/wordsize-64/e_cosh.c b/sysdeps/ieee754/dbl-64/wordsize-64/e_cosh.c
index 8459352..ecf8210 100644
--- a/sysdeps/ieee754/dbl-64/wordsize-64/e_cosh.c
+++ b/sysdeps/ieee754/dbl-64/wordsize-64/e_cosh.c
@@ -33,6 +33,7 @@
 
 #include <math.h>
 #include <math_private.h>
+#include <stap-probe.h>
 
 static const double one = 1.0, half=0.5, huge = 1.0e300;
 
@@ -52,17 +53,23 @@ __ieee754_cosh (double x)
 		if(ix<0x3fd62e43) {
 		    t = __expm1(fabs(x));
 		    w = one+t;
+		    LIBC_PROBE (cosh_probe, 2, 1, &x);
 		    if (ix<0x3c800000) return w;	/* cosh(tiny) = 1 */
 		    return one+(t*t)/(w+w);
 		}
 
+		    LIBC_PROBE (cosh_probe, 2, 2, &x);
 	    /* |x| in [0.5*ln2,22], return (exp(|x|)+1/exp(|x|)/2; */
 		t = __ieee754_exp(fabs(x));
 		return half*t+half/t;
 	}
 
     /* |x| in [22, log(maxdouble)] return half*exp(|x|) */
-	if (ix < 0x40862e42)  return half*__ieee754_exp(fabs(x));
+	if (ix < 0x40862e42)  
+	{
+		    LIBC_PROBE (cosh_probe, 2, 3, &x);
+	return half*__ieee754_exp(fabs(x));
+	}
 
     /* |x| in [log(maxdouble), overflowthresold] */
 	int64_t fix;
@@ -71,6 +78,7 @@ __ieee754_cosh (double x)
 	if (fix <= UINT64_C(0x408633ce8fb9f87d)) {
 	    w = __ieee754_exp(half*fabs(x));
 	    t = half*w;
+		    LIBC_PROBE (cosh_probe, 2, 4, &x);
 	    return t*w;
 	}
 

-----------------------------------------------------------------------


hooks/post-receive
-- 
GNU C Library master sources


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]