diff options
Diffstat (limited to 'sysdeps/ia64/fpu/e_sqrt.S')
-rw-r--r-- | sysdeps/ia64/fpu/e_sqrt.S | 68 |
1 files changed, 25 insertions, 43 deletions
diff --git a/sysdeps/ia64/fpu/e_sqrt.S b/sysdeps/ia64/fpu/e_sqrt.S index dd057f58ee..53e60ef23f 100644 --- a/sysdeps/ia64/fpu/e_sqrt.S +++ b/sysdeps/ia64/fpu/e_sqrt.S @@ -1,11 +1,11 @@ .file "sqrt.s" -// Copyright (C) 2000, 2001, Intel Corporation + +// Copyright (c) 2000 - 2003, Intel Corporation // All rights reserved. // -// Contributed 2/2/2000 by John Harrison, Ted Kubaska, Bob Norin, Shane Story, -// and Ping Tak Peter Tang of the Computational Software Lab, Intel Corporation. -// +// Contributed 2000 by the Intel Numerics Group, Intel Corporation +// // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions are // met: @@ -20,7 +20,7 @@ // * The name of Intel Corporation may not be used to endorse or promote // products derived from this software without specific prior written // permission. -// + // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR @@ -35,27 +35,28 @@ // // Intel Corporation is the author of this code, and requests that all // problem reports or change requests be submitted to it directly at -// http://developer.intel.com/opensource. +// http://www.intel.com/software/products/opensource/libraries/num.htm. // -// ******************************************************************** +//******************************************************************** // History -// ******************************************************************** -// 2/02/00 Initial version -// 4/04/00 Unwind support added -// 8/15/00 Bundle added after call to __libm_error_support to properly +//******************************************************************** +// 02/02/00 Initial version +// 04/04/00 Unwind support added +// 08/15/00 Bundle added after call to __libm_error_support to properly // set [the previously overwritten] GR_Parameter_RESULT. +// 02/10/03 Reordered header: .section, .global, .proc, .align // -// ******************************************************************** +//******************************************************************** // // Function: Combined sqrt(x), where // _ // sqrt(x) = |x, for double precision x values // -// ******************************************************************** +//******************************************************************** // // Accuracy: Correctly Rounded // -// ******************************************************************** +//******************************************************************** // // Resources Used: // @@ -68,7 +69,7 @@ // // Predicate Registers: p6, p7, p8 // -// ********************************************************************* +//********************************************************************* // // IEEE Special Conditions: // @@ -78,15 +79,13 @@ // sqrt(+/-0) = +/-0 // sqrt(negative) = QNaN and error handling is called // -// ********************************************************************* +//********************************************************************* // // Implementation: // // Modified Newton-Raphson Algorithm // -// ********************************************************************* - -#include "libm_support.h" +//********************************************************************* GR_SAVE_PFS = r33 GR_SAVE_B0 = r34 @@ -98,19 +97,7 @@ GR_Parameter_RESULT = r39 .section .text -.proc sqrt# -.global sqrt# -.align 64 - -sqrt: -#ifdef _LIBC -.global __sqrt -.type __sqrt,@function -__sqrt: -.global __ieee754_sqrt -.type __ieee754_sqrt,@function -__ieee754_sqrt: -#endif +GLOBAL_IEEE754_ENTRY(sqrt) { .mfi alloc r32= ar.pfs,0,5,4,0 frsqrta.s0 f7,p6=f8 @@ -255,7 +242,7 @@ __ieee754_sqrt: { .mfb nop.m 0 - (p0) mov f8 = f7 + mov f8 = f7 (p8) br.ret.sptk b0 ;; } { .mfb @@ -264,12 +251,7 @@ __ieee754_sqrt: (p7) br.cond.sptk __libm_error_region ;; } // END DOUBLE PRECISION MINIMUM LATENCY SQUARE ROOT ALGORITHM -.endp sqrt# -ASM_SIZE_DIRECTIVE(sqrt) -#ifdef _LIBC -ASM_SIZE_DIRECTIVE(__sqrt) -ASM_SIZE_DIRECTIVE(__ieee754_sqrt) -#endif +GLOBAL_IEEE754_END(sqrt) // Stack operations when calling error support. // (1) (2) (3) (call) (4) @@ -286,8 +268,7 @@ ASM_SIZE_DIRECTIVE(__ieee754_sqrt) // save gp restore ar.pfs -.proc __libm_error_region -__libm_error_region: +LOCAL_LIBM_ENTRY(__libm_error_region) // // This branch includes all those special values that are not negative, @@ -352,8 +333,9 @@ __libm_error_region: br.ret.sptk b0 // Return };; -.endp __libm_error_region -ASM_SIZE_DIRECTIVE(__libm_error_region) +LOCAL_LIBM_END(__libm_error_region) + + .type __libm_error_support#,@function |