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


  10  * See the License for the specific language governing permissions
  11  * and limitations under the License.
  12  *
  13  * When distributing Covered Code, include this CDDL HEADER in each
  14  * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  15  * If applicable, add the following below this CDDL HEADER, with the
  16  * fields enclosed by brackets "[]" replaced with your own identifying
  17  * information: Portions Copyright [yyyy] [name of copyright owner]
  18  *
  19  * CDDL HEADER END
  20  */
  21 
  22 /*
  23  * Copyright 2011 Nexenta Systems, Inc.  All rights reserved.
  24  */
  25 /*
  26  * Copyright 2006 Sun Microsystems, Inc.  All rights reserved.
  27  * Use is subject to license terms.
  28  */
  29 
  30 #if defined(ELFOBJ)
  31 #pragma weak isinfl = __isinfl
  32 #pragma weak isnormall = __isnormall
  33 #pragma weak issubnormall = __issubnormall
  34 #pragma weak iszerol = __iszerol
  35 #pragma weak signbitl = __signbitl
  36 #endif
  37 
  38 #include "libm.h"
  39 
  40 #if defined(__sparc)
  41 int
  42 isinfl(long double x) {
  43         int *px = (int *) &x;
  44         return ((px[0] & ~0x80000000) == 0x7fff0000 && px[1] == 0 &&
  45                 px[2] == 0 && px[3] == 0);
  46 }
  47 
  48 int
  49 isnormall(long double x) {
  50         int *px = (int *) &x;
  51         return ((unsigned) ((px[0] & 0x7fff0000) - 0x10000) < 0x7ffe0000);
  52 }
  53 
  54 int
  55 issubnormall(long double x) {
  56         int *px = (int *) &x;




  10  * See the License for the specific language governing permissions
  11  * and limitations under the License.
  12  *
  13  * When distributing Covered Code, include this CDDL HEADER in each
  14  * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  15  * If applicable, add the following below this CDDL HEADER, with the
  16  * fields enclosed by brackets "[]" replaced with your own identifying
  17  * information: Portions Copyright [yyyy] [name of copyright owner]
  18  *
  19  * CDDL HEADER END
  20  */
  21 
  22 /*
  23  * Copyright 2011 Nexenta Systems, Inc.  All rights reserved.
  24  */
  25 /*
  26  * Copyright 2006 Sun Microsystems, Inc.  All rights reserved.
  27  * Use is subject to license terms.
  28  */
  29 

  30 #pragma weak isinfl = __isinfl
  31 #pragma weak isnormall = __isnormall
  32 #pragma weak issubnormall = __issubnormall
  33 #pragma weak iszerol = __iszerol
  34 #pragma weak signbitl = __signbitl

  35 
  36 #include "libm.h"
  37 
  38 #if defined(__sparc)
  39 int
  40 isinfl(long double x) {
  41         int *px = (int *) &x;
  42         return ((px[0] & ~0x80000000) == 0x7fff0000 && px[1] == 0 &&
  43                 px[2] == 0 && px[3] == 0);
  44 }
  45 
  46 int
  47 isnormall(long double x) {
  48         int *px = (int *) &x;
  49         return ((unsigned) ((px[0] & 0x7fff0000) - 0x10000) < 0x7ffe0000);
  50 }
  51 
  52 int
  53 issubnormall(long double x) {
  54         int *px = (int *) &x;