30 static partial class fdlibm
32 static int __HI(
double x)
34 return (
int)(BitConverter.DoubleToInt64Bits(x) >> 32);
37 static int __LO(
double x)
39 return (
int)BitConverter.DoubleToInt64Bits(x);
42 static double __HI(
double x,
int i)
44 long l = BitConverter.DoubleToInt64Bits(x) & 0xFFFFFFFFL;
45 long h = (long)i << 32;
46 return BitConverter.Int64BitsToDouble(l | h);
49 static double __LO(
double x,
int i)
51 long h = BitConverter.DoubleToInt64Bits(x) & ~0xFFFFFFFFL;
52 return BitConverter.Int64BitsToDouble(h | (uint)i);
55 static double fabs(
double d)
60 static double sqrt(
double d)
65 static double copysign(
double x,
double y)
67 x = __HI(x, (__HI(x) & 0x7fffffff) | (__HI(y) & unchecked((
int)0x80000000)));