Home
last modified time | relevance | path

Searched refs:copySign (Results 1 – 12 of 12) sorted by relevance

/libcore/ojluni/src/main/java/sun/misc/
DFpUtils.java171 return Math.copySign(magnitude, sign); in rawCopySign()
192 return Math.copySign(magnitude, sign); in rawCopySign()
806 public static double copySign(double magnitude, double sign) { in copySign() method in FpUtils
807 return StrictMath.copySign(magnitude, sign); in copySign()
824 public static float copySign(float magnitude, float sign) { in copySign() method in FpUtils
825 return StrictMath.copySign(magnitude, sign); in copySign()
/libcore/ojluni/src/main/java/java/lang/
DStrictMath.java450 double sign = Math.copySign(1.0, a); // preserve sign info in rint()
1387 public static double copySign(double magnitude, double sign) { in copySign() method in StrictMath
1388 return Math.copySign(magnitude, (Double.isNaN(sign)?1.0d:sign)); in copySign()
1403 public static float copySign(float magnitude, float sign) { in copySign() method in StrictMath
1404 return Math.copySign(magnitude, (Float.isNaN(sign)?1.0f:sign)); in copySign()
DMath.java1547 return (d == 0.0 || Double.isNaN(d))?d:copySign(1.0, d); in signum()
1568 return (f == 0.0f || Float.isNaN(f))?f:copySign(1.0f, f); in signum()
1781 public static double copySign(double magnitude, double sign) { in copySign() method in Math
1804 public static float copySign(float magnitude, float sign) { in copySign() method in Math
DDouble.java294 if (Math.copySign(1.0, d) == -1.0) // value is negative, in toHexString()
/libcore/luni/src/test/resources/
Dmath_java_only.csv2133 copySign,-0x1.f0df8a466700bp1,-0x1.f0df8a466700bp1,-0x1.6e938e3732539p-1
2134 copySign,-0x1.58e4f34672f61p4,0x1.58e4f34672f61p4,-0x1.27d6a2e67009cp-1
2135 copySign,-0x1.f4b9bf237c55fp0,-0x1.f4b9bf237c55fp0,-0x1.37c0ebff02017p0
2136 copySign,-0x1.59f3d2a9fe64ap2,-0x1.59f3d2a9fe64ap2,-0x1.2669d7ca6a8d6p0
2137 copySign,-0x1.c46d4baa04314p-2,-0x1.c46d4baa04314p-2,-0x1.5d0597ad91f24p-2
2138 copySign,0x1.27953254ab2d4p0,-0x1.27953254ab2d4p0,0x1.cf0f007876816p-1
2139 copySign,-0x1.ee50997f5ec0cp-2,0x1.ee50997f5ec0cp-2,-0x1.1fe2c0d6e4b9bp-1
2140 copySign,0x1.3318225589ce5p1,0x1.3318225589ce5p1,0x1.8013386023341p1
2141 copySign,0x1.836934e49ccf1p-1,-0x1.836934e49ccf1p-1,0x1.23098c339673cp1
2142 copySign,-0x1.a76ccea1e588ap0,-0x1.a76ccea1e588ap0,-0x1.1bf459b597376p-1
[all …]
/libcore/ojluni/annotations/hiddenapi/sun/misc/
DFpUtils.java139 public static double copySign(double magnitude, double sign) { in copySign() method in FpUtils
144 public static float copySign(float magnitude, float sign) { in copySign() method in FpUtils
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/lang/
DStrictMathTest.java194 .copySign(magnitude, Double.NaN))); in test_copySign_DD()
196 .copySign(Double.NaN, magnitude))); in test_copySign_DD()
201 .copySign(magnitude, sign)); in test_copySign_DD()
218 .copySign(Double.NaN, Double.NaN))); in test_copySign_DD()
221 StrictMath.copySign((Double) null, 2.3); in test_copySign_DD()
227 StrictMath.copySign(2.3, (Double) null); in test_copySign_DD()
233 StrictMath.copySign((Double) null, (Double) null); in test_copySign_DD()
240 assertEquals(1.0, StrictMath.copySign(1.0, d), 0d); in test_copySign_DD()
258 absMagnitudeBits, Float.floatToIntBits(StrictMath.copySign( in test_copySign_FF()
261 .copySign(Float.NaN, magnitude))); in test_copySign_FF()
[all …]
DMathTest.java177 absMagnitudeBits, Double.doubleToLongBits(Math.copySign( in test_copySign_DD()
179 assertTrue("The result should be NaN.", Double.isNaN(Math.copySign( in test_copySign_DD()
184 final long resultBits = Double.doubleToLongBits(Math.copySign( in test_copySign_DD()
201 assertTrue("The result should be NaN.", Double.isNaN(Math.copySign( in test_copySign_DD()
205 Math.copySign((Double) null, 2.3); in test_copySign_DD()
211 Math.copySign(2.3, (Double) null); in test_copySign_DD()
217 Math.copySign((Double) null, (Double) null); in test_copySign_DD()
249 absMagnitudeBits, Float.floatToIntBits(Math.copySign( in test_copySign_FF()
251 assertTrue("The result should be NaN.", Float.isNaN(Math.copySign( in test_copySign_FF()
256 final int resultBits = Float.floatToIntBits(Math.copySign( in test_copySign_FF()
[all …]
/libcore/ojluni/annotations/mmodule/java/lang/
DMath.annotated.java162 public static double copySign(double magnitude, double sign) { throw new RuntimeException("Stub!");… in copySign() method in Math
164 public static float copySign(float magnitude, float sign) { throw new RuntimeException("Stub!"); } in copySign() method in Math
/libcore/benchmarks/src/benchmarks/regression/
DMathBenchmark.java117 result = Math.copySign(d, d); in timeCopySignD()
125 result = Math.copySign(f, f); in timeCopySignF()
133 result = StrictMath.copySign(d, d); in timeCopySignD_strict()
141 result = StrictMath.copySign(f, f); in timeCopySignF_strict()
DStrictMathBenchmark.java123 StrictMath.copySign(d, d); in timeCopySignD()
129 StrictMath.copySign(f, f); in timeCopySignF()
/libcore/luni/src/test/java/libcore/java/lang/
DOldAndroidMathTest.java114 double negativeZero = Math.copySign(0d, -1d); in testAtanDZeroValues()
116 assertTrue("Wrong sign for atan(0)", Math.copySign(1, Math.atan(0d)) == 1); in testAtanDZeroValues()
119 assertTrue("Wrong sign for atan(-0)", Math.copySign(1, Math.atan(negativeZero)) == -1); in testAtanDZeroValues()
142 double negativeZero = Math.copySign(0d, -1d); in testAtan2DDZeroValues()
145 Math.copySign(1, Math.atan2(+0, +0)) == 1);; in testAtan2DDZeroValues()
149 Math.copySign(1, Math.atan2(negativeZero, +0)) == -1); in testAtan2DDZeroValues()