components/libgsl/patches/fix-linear-optimization.patch
author zihao.zhu@oracle.com <zihao.zhu@oracle.com>
Fri, 17 Jul 2015 14:10:26 -0600
branchs11-update
changeset 4662 291e4ab0706c
parent 4388 8bd4e7260c34
permissions -rw-r--r--
20220521 OpenLDAP TLS Protocol/Ciphersuite selection for nsswitch-ldap 20604417 problem in SERVICE/OPENLDAP 18218606 bad runpaths in openldap binaries after 12.3 switch

Fix an optimization issue seen with Studion 12.1 with Solaris 11.3 when
compiling with -xO4. The problem has been fixed in Studio 12.4, so the
issue will go away when the Solaris 11.X release updates to that in its CBE.

This patch will not be sent upstream.

--- gsl-1.16/interpolation/linear.c.orig	2015-06-01 15:58:46.278682889 -0700
+++ gsl-1.16/interpolation/linear.c	2015-06-01 16:28:26.000366577 -0700
@@ -157,7 +157,7 @@
   *result = 0.0;
   
   /* interior intervals */
-  for(i=index_a; i<=index_b; i++) {
+  for(i=index_a; i<index_b+1; i++) {
     const double x_hi = x_array[i + 1];
     const double x_lo = x_array[i];
     const double y_lo = y_array[i];