annotate test/compiler/6539464/Test.java @ 807:d44bdab1c03d

6843694: G1: assert(index < _vs.committed_size(),"bad index"), g1BlockOffsetTable.inline.hpp:55 Summary: For heaps larger than 32Gb, the number of heap regions overflows the data type used to hold the region index in the SparsePRT structure. Changed the region indexes, card indexes, and RSet hash table buckets to ints and added some size overflow guarantees. Reviewed-by: ysr, tonyp
author johnc
date Thu, 11 Jun 2009 17:19:33 -0700
parents 819880572f09
children c18cbe5936b8
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
706
819880572f09 6539464: Math.log() produces inconsistent results between successive runs.
never
parents:
diff changeset
1 /*
819880572f09 6539464: Math.log() produces inconsistent results between successive runs.
never
parents:
diff changeset
2 * Copyright 2009 Sun Microsystems, Inc. All Rights Reserved.
819880572f09 6539464: Math.log() produces inconsistent results between successive runs.
never
parents:
diff changeset
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
819880572f09 6539464: Math.log() produces inconsistent results between successive runs.
never
parents:
diff changeset
4 *
819880572f09 6539464: Math.log() produces inconsistent results between successive runs.
never
parents:
diff changeset
5 * This code is free software; you can redistribute it and/or modify it
819880572f09 6539464: Math.log() produces inconsistent results between successive runs.
never
parents:
diff changeset
6 * under the terms of the GNU General Public License version 2 only, as
819880572f09 6539464: Math.log() produces inconsistent results between successive runs.
never
parents:
diff changeset
7 * published by the Free Software Foundation.
819880572f09 6539464: Math.log() produces inconsistent results between successive runs.
never
parents:
diff changeset
8 *
819880572f09 6539464: Math.log() produces inconsistent results between successive runs.
never
parents:
diff changeset
9 * This code is distributed in the hope that it will be useful, but WITHOUT
819880572f09 6539464: Math.log() produces inconsistent results between successive runs.
never
parents:
diff changeset
10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
819880572f09 6539464: Math.log() produces inconsistent results between successive runs.
never
parents:
diff changeset
11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
819880572f09 6539464: Math.log() produces inconsistent results between successive runs.
never
parents:
diff changeset
12 * version 2 for more details (a copy is included in the LICENSE file that
819880572f09 6539464: Math.log() produces inconsistent results between successive runs.
never
parents:
diff changeset
13 * accompanied this code).
819880572f09 6539464: Math.log() produces inconsistent results between successive runs.
never
parents:
diff changeset
14 *
819880572f09 6539464: Math.log() produces inconsistent results between successive runs.
never
parents:
diff changeset
15 * You should have received a copy of the GNU General Public License version
819880572f09 6539464: Math.log() produces inconsistent results between successive runs.
never
parents:
diff changeset
16 * 2 along with this work; if not, write to the Free Software Foundation,
819880572f09 6539464: Math.log() produces inconsistent results between successive runs.
never
parents:
diff changeset
17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
819880572f09 6539464: Math.log() produces inconsistent results between successive runs.
never
parents:
diff changeset
18 *
819880572f09 6539464: Math.log() produces inconsistent results between successive runs.
never
parents:
diff changeset
19 * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
819880572f09 6539464: Math.log() produces inconsistent results between successive runs.
never
parents:
diff changeset
20 * CA 95054 USA or visit www.sun.com if you need additional information or
819880572f09 6539464: Math.log() produces inconsistent results between successive runs.
never
parents:
diff changeset
21 * have any questions.
819880572f09 6539464: Math.log() produces inconsistent results between successive runs.
never
parents:
diff changeset
22 */
819880572f09 6539464: Math.log() produces inconsistent results between successive runs.
never
parents:
diff changeset
23
819880572f09 6539464: Math.log() produces inconsistent results between successive runs.
never
parents:
diff changeset
24 /**
819880572f09 6539464: Math.log() produces inconsistent results between successive runs.
never
parents:
diff changeset
25 * @test
819880572f09 6539464: Math.log() produces inconsistent results between successive runs.
never
parents:
diff changeset
26 * @bug 6539464
819880572f09 6539464: Math.log() produces inconsistent results between successive runs.
never
parents:
diff changeset
27 * @summary Math.log() produces inconsistent results between successive runs.
819880572f09 6539464: Math.log() produces inconsistent results between successive runs.
never
parents:
diff changeset
28 *
819880572f09 6539464: Math.log() produces inconsistent results between successive runs.
never
parents:
diff changeset
29 * @run main/othervm -Xcomp -XX:CompileOnly=Test.main Test
819880572f09 6539464: Math.log() produces inconsistent results between successive runs.
never
parents:
diff changeset
30 */
819880572f09 6539464: Math.log() produces inconsistent results between successive runs.
never
parents:
diff changeset
31
819880572f09 6539464: Math.log() produces inconsistent results between successive runs.
never
parents:
diff changeset
32 public class Test {
819880572f09 6539464: Math.log() produces inconsistent results between successive runs.
never
parents:
diff changeset
33 static double log_value = 17197;
819880572f09 6539464: Math.log() produces inconsistent results between successive runs.
never
parents:
diff changeset
34 static double log_result = Math.log(log_value);
819880572f09 6539464: Math.log() produces inconsistent results between successive runs.
never
parents:
diff changeset
35
819880572f09 6539464: Math.log() produces inconsistent results between successive runs.
never
parents:
diff changeset
36 public static void main(String[] args) throws Exception {
819880572f09 6539464: Math.log() produces inconsistent results between successive runs.
never
parents:
diff changeset
37 for (int i = 0; i < 1000000; i++) {
819880572f09 6539464: Math.log() produces inconsistent results between successive runs.
never
parents:
diff changeset
38 double log_result2 = Math.log(log_value);
819880572f09 6539464: Math.log() produces inconsistent results between successive runs.
never
parents:
diff changeset
39 if (log_result2 != log_result) {
819880572f09 6539464: Math.log() produces inconsistent results between successive runs.
never
parents:
diff changeset
40 throw new InternalError("Math.log produces inconsistent results: " + log_result2 + " != " + log_result);
819880572f09 6539464: Math.log() produces inconsistent results between successive runs.
never
parents:
diff changeset
41 }
819880572f09 6539464: Math.log() produces inconsistent results between successive runs.
never
parents:
diff changeset
42 }
819880572f09 6539464: Math.log() produces inconsistent results between successive runs.
never
parents:
diff changeset
43 }
819880572f09 6539464: Math.log() produces inconsistent results between successive runs.
never
parents:
diff changeset
44 }