Print this page
5262 libm needs to be carefully unifdef'd
5268 libm doesn't need to hide symbols which are already local

*** 25,43 **** /* * Copyright 2006 Sun Microsystems, Inc. All rights reserved. * Use is subject to license terms. */ - #if defined(ELFOBJ) #pragma weak scalbln = __scalbln - #endif #include "libm.h" #include <float.h> /* DBL_MAX, DBL_MIN */ static const double twom54 = 5.5511151231257827021181583404541015625e-17; ! #if defined(USE_FPSCALE) || defined(__x86) static const double two52 = 4503599627370496.0; #else /* * Normalize non-zero subnormal x and return biased exponent of x in [-51,0] */ --- 25,41 ---- /* * Copyright 2006 Sun Microsystems, Inc. All rights reserved. * Use is subject to license terms. */ #pragma weak scalbln = __scalbln #include "libm.h" #include <float.h> /* DBL_MAX, DBL_MIN */ static const double twom54 = 5.5511151231257827021181583404541015625e-17; ! #if defined(__x86) static const double two52 = 4503599627370496.0; #else /* * Normalize non-zero subnormal x and return biased exponent of x in [-51,0] */
*** 67,77 **** } px[HIWORD] = (px[HIWORD] & 0x80000000) | v; px[LOWORD] = w; return (1 - s); } ! #endif /* defined(USE_FPSCALE) */ double scalbln(double x, long n) { int *px = (int *) &x, ix, k; --- 65,75 ---- } px[HIWORD] = (px[HIWORD] & 0x80000000) | v; px[LOWORD] = w; return (1 - s); } ! #endif /* defined(__x86) */ double scalbln(double x, long n) { int *px = (int *) &x, ix, k;
*** 85,95 **** return (x + x); #endif if ((px[LOWORD] | ix) == 0 || n == 0) return (x); if (k == 0) { ! #if defined(USE_FPSCALE) || defined(__x86) x *= two52; k = ((px[HIWORD] & ~0x80000000) >> 20) - 52; #else k = ilogb_biased((unsigned *) px); #endif --- 83,93 ---- return (x + x); #endif if ((px[LOWORD] | ix) == 0 || n == 0) return (x); if (k == 0) { ! #if defined(__x86) x *= two52; k = ((px[HIWORD] & ~0x80000000) >> 20) - 52; #else k = ilogb_biased((unsigned *) px); #endif