2362N/A * Copyright (c) 2004, Oracle and/or its affiliates. All rights reserved. 809N/A * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 809N/A * This code is free software; you can redistribute it and/or modify it 809N/A * under the terms of the GNU General Public License version 2 only, as 809N/A * published by the Free Software Foundation. 809N/A * This code is distributed in the hope that it will be useful, but WITHOUT 809N/A * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 809N/A * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 809N/A * version 2 for more details (a copy is included in the LICENSE file that 809N/A * accompanied this code). 809N/A * You should have received a copy of the GNU General Public License version 809N/A * 2 along with this work; if not, write to the Free Software Foundation, 809N/A * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 2362N/A * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 2362N/A * or visit www.oracle.com if you need additional information or have any 809N/A * @summary Tests for {Math, StrictMath}.pow 809N/A * @author Joseph D. Darcy 809N/A * Test for bad negation implementation. 809N/A * Test cross-product of different kinds of arguments. 809N/A/**/ (
double) -((
1L<<
53)+
2L),
809N/A/**/ (
double) -((
1L<<
53)),
809N/A/**/ (
double) -((
1L<<
53)-
1L),
809N/A/**/ -
1.0000000000000004,
809N/A/* < -1.0 */ -
1.0000000000000002,
// nextAfter(-1.0, -oo) 809N/A/* > -1.0 */ -
0.9999999999999999,
// nextAfter(-1.0, +oo) 809N/A/* > -1.0 */ -
0.9999999999999998,
809N/A/**/ +
0.9999999999999998,
809N/A/* < +1.0 */ +
0.9999999999999999,
// nextAfter(-1.0, +oo) 809N/A/* > 1.0 */ +
1.0000000000000002,
// nextAfter(+1.0, +oo) 809N/A/**/ +
1.0000000000000004,
809N/A/**/ (
double) ((
1L<<
53)-
1L),
809N/A/**/ (
double) ((
1L<<
53)),
809N/A/**/ (
double) ((
1L<<
53)+
2L),
809N/A if(y >
0) {
// x ^ (+oo) 809N/A }
/* end Double.isInfinite(y) */ 809N/A // go to next iteration 809N/A static double f3(
double x,
double y) {
809N/A * Return classification of argument: -1 for non-integers, 0 for 809N/A * even integers, 1 for odd integers. 809N/A // Determine if argument is an odd or even integer. 809N/A if(a+
1.0 == a) {
// a > maximum odd floating-point integer 809N/A return 0;
// Large integers are all even 809N/A else {
// Convert double -> long and look at low-order bit