author | simonis |
Wed, 10 Jul 2013 09:14:25 -0700 | |
changeset 22818 | 34cd99df9940 |
parent 5547 | f4b087cbb361 |
permissions | -rw-r--r-- |
4453
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
1 |
/* |
5547
f4b087cbb361
6941466: Oracle rebranding changes for Hotspot repositories
trims
parents:
4453
diff
changeset
|
2 |
* Copyright (c) 2009, Oracle and/or its affiliates. All rights reserved. |
4453
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
3 |
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
4 |
* |
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
5 |
* This code is free software; you can redistribute it and/or modify it |
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
6 |
* under the terms of the GNU General Public License version 2 only, as |
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
7 |
* published by the Free Software Foundation. |
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
8 |
* |
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
9 |
* This code is distributed in the hope that it will be useful, but WITHOUT |
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
10 |
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or |
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
11 |
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License |
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
12 |
* version 2 for more details (a copy is included in the LICENSE file that |
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
13 |
* accompanied this code). |
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
14 |
* |
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
15 |
* You should have received a copy of the GNU General Public License version |
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
16 |
* 2 along with this work; if not, write to the Free Software Foundation, |
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
17 |
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. |
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
18 |
* |
5547
f4b087cbb361
6941466: Oracle rebranding changes for Hotspot repositories
trims
parents:
4453
diff
changeset
|
19 |
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA |
f4b087cbb361
6941466: Oracle rebranding changes for Hotspot repositories
trims
parents:
4453
diff
changeset
|
20 |
* or visit www.oracle.com if you need additional information or have any |
f4b087cbb361
6941466: Oracle rebranding changes for Hotspot repositories
trims
parents:
4453
diff
changeset
|
21 |
* questions. |
4453
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
22 |
*/ |
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
23 |
|
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
24 |
/** |
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
25 |
* @test |
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
26 |
* @bug 6901572 |
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
27 |
* @summary JVM 1.6.16 crash on loops: assert(has_node(i),"") |
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
28 |
* |
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
29 |
* @run main/othervm Test |
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
30 |
*/ |
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
31 |
|
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
32 |
|
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
33 |
public class Test { |
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
34 |
|
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
35 |
public static void main(String[] args) { |
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
36 |
for (int i = 0; i < 2; i++) |
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
37 |
NestedLoop(); |
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
38 |
} |
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
39 |
|
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
40 |
public static long NestedLoop() { |
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
41 |
final int n = 50; |
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
42 |
long startTime = System.currentTimeMillis(); |
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
43 |
int x = 0; |
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
44 |
for(int a = 0; a < n; a++) |
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
45 |
for(int b = 0; b < n; b++) |
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
46 |
for(int c = 0; c < n; c++) |
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
47 |
for(int d = 0; d < n; d++) |
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
48 |
for(int e = 0; e < n; e++) |
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
49 |
for(int f = 0; f < n; f++) |
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
50 |
x++; |
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
51 |
long stopTime = System.currentTimeMillis(); |
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
52 |
|
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
53 |
return stopTime - startTime; |
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
54 |
} |
a431438150d4
6901572: JVM 1.6.16 crash on loops: assert(has_node(i),"")
cfang
parents:
diff
changeset
|
55 |
} |