this repo has no description
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

at fixPythonPipStalling 32 lines 781 B view raw
1/* 2 * xmm_sqrt.c 3 * xmmLibm 4 * 5 * Created by Ian Ollmann, Ph.D. on 7/14/05. 6 * Copyright © 2005 Apple Computer, Inc. All rights reserved. 7 * 8 * This set of functions may seem a little silly at first. The compiler can generate 9 * sqrtsd or sqrtsf inline, so why do we need a function? It appears that people can 10 * make a function pointer to sqrt and call that. Therefore an implementation of sqrt() 11 * should probably exist. We define a trivial one here. 12 * 13 */ 14 15#include "xmmLibm_prefix.h" 16#include "math.h" 17 18double sqrt( double x ) 19{ 20 xDouble f = DOUBLE_2_XDOUBLE( x ); 21 f = _MM_SQRT_SD(f); 22 return XDOUBLE_2_DOUBLE( f ); 23} 24 25float sqrtf( float x ) 26{ 27 xFloat f = FLOAT_2_XFLOAT( x ); 28 f = _mm_sqrt_ss(f); 29 return XFLOAT_2_FLOAT( f ); 30} 31 32