author | shade |
Wed, 24 Feb 2016 18:43:51 +0300 | |
changeset 36317 | 5c78a6c34390 |
child 36325 | 1330e79162ac |
permissions | -rw-r--r-- |
36317
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
1 |
/* |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
2 |
* Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved. |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
3 |
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
4 |
* |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
5 |
* This code is free software; you can redistribute it and/or modify it |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
6 |
* under the terms of the GNU General Public License version 2 only, as |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
7 |
* published by the Free Software Foundation. |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
8 |
* |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
9 |
* This code is distributed in the hope that it will be useful, but WITHOUT |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
10 |
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
11 |
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
12 |
* version 2 for more details (a copy is included in the LICENSE file that |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
13 |
* accompanied this code). |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
14 |
* |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
15 |
* You should have received a copy of the GNU General Public License version |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
16 |
* 2 along with this work; if not, write to the Free Software Foundation, |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
17 |
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
18 |
* |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
19 |
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
20 |
* or visit www.oracle.com if you need additional information or have any |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
21 |
* questions. |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
22 |
*/ |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
23 |
|
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
24 |
/* |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
25 |
* @test |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
26 |
* @bug 8150102 8150514 |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
27 |
* @summary C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102 |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
28 |
* @run main/othervm -XX:CompileThreshold=100 -XX:+TieredCompilation -XX:TieredStopAtLevel=1 -XX:-BackgroundCompilation CanonicalizeArrayLength |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
29 |
* |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
30 |
*/ |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
31 |
|
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
32 |
public class CanonicalizeArrayLength { |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
33 |
int[] arr = new int[42]; |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
34 |
int[] arrNull = null; |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
35 |
|
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
36 |
final int[] finalArr = new int[42]; |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
37 |
final int[] finalArrNull = null; |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
38 |
|
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
39 |
static int[] staticArr = new int[42]; |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
40 |
static int[] staticArrNull = null; |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
41 |
|
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
42 |
static final int[] staticFinalArr = new int[42]; |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
43 |
static final int[] staticFinalArrNull = null; |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
44 |
|
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
45 |
public static void main(String... args) { |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
46 |
CanonicalizeArrayLength t = new CanonicalizeArrayLength(); |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
47 |
for (int i = 0; i < 20000; i++) { |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
48 |
if (t.testLocal() != 42) |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
49 |
throw new IllegalStateException(); |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
50 |
if (t.testLocalNull() != 42) |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
51 |
throw new IllegalStateException(); |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
52 |
if (t.testField() != 42) |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
53 |
throw new IllegalStateException(); |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
54 |
if (t.testFieldNull() != 42) |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
55 |
throw new IllegalStateException(); |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
56 |
if (t.testFinalField() != 42) |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
57 |
throw new IllegalStateException(); |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
58 |
if (t.testFinalFieldNull() != 42) |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
59 |
throw new IllegalStateException(); |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
60 |
if (t.testStaticField() != 42) |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
61 |
throw new IllegalStateException(); |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
62 |
if (t.testStaticFieldNull() != 42) |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
63 |
throw new IllegalStateException(); |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
64 |
if (t.testStaticFinalField() != 42) |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
65 |
throw new IllegalStateException(); |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
66 |
if (t.testStaticFinalFieldNull() != 42) |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
67 |
throw new IllegalStateException(); |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
68 |
} |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
69 |
} |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
70 |
|
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
71 |
int testField() { |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
72 |
try { |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
73 |
return arr.length; |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
74 |
} catch (Throwable t) { |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
75 |
return -1; |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
76 |
} |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
77 |
} |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
78 |
|
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
79 |
int testFieldNull() { |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
80 |
try { |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
81 |
return arrNull.length; |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
82 |
} catch (Throwable t) { |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
83 |
return 42; |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
84 |
} |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
85 |
} |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
86 |
|
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
87 |
int testFinalField() { |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
88 |
try { |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
89 |
return finalArr.length; |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
90 |
} catch (Throwable t) { |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
91 |
return -1; |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
92 |
} |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
93 |
} |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
94 |
|
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
95 |
int testFinalFieldNull() { |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
96 |
try { |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
97 |
return finalArrNull.length; |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
98 |
} catch (Throwable t) { |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
99 |
return 42; |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
100 |
} |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
101 |
} |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
102 |
|
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
103 |
int testStaticField() { |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
104 |
try { |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
105 |
return staticArr.length; |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
106 |
} catch (Throwable t) { |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
107 |
return -1; |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
108 |
} |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
109 |
} |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
110 |
|
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
111 |
int testStaticFieldNull() { |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
112 |
try { |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
113 |
return staticArrNull.length; |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
114 |
} catch (Throwable t) { |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
115 |
return 42; |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
116 |
} |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
117 |
} |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
118 |
|
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
119 |
int testStaticFinalField() { |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
120 |
try { |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
121 |
return staticFinalArr.length; |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
122 |
} catch (Throwable t) { |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
123 |
return -1; |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
124 |
} |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
125 |
} |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
126 |
|
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
127 |
int testStaticFinalFieldNull() { |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
128 |
try { |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
129 |
return staticFinalArrNull.length; |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
130 |
} catch (Throwable t) { |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
131 |
return 42; |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
132 |
} |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
133 |
} |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
134 |
|
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
135 |
int testLocal() { |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
136 |
int[] arr = new int[42]; |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
137 |
try { |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
138 |
return arr.length; |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
139 |
} catch (Throwable t) { |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
140 |
return -1; |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
141 |
} |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
142 |
} |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
143 |
|
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
144 |
int testLocalNull() { |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
145 |
int[] arrNull = null; |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
146 |
try { |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
147 |
return arrNull.length; |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
148 |
} catch (Throwable t) { |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
149 |
return 42; |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
150 |
} |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
151 |
} |
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
152 |
|
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
153 |
|
5c78a6c34390
8150514: C1 crashes in Canonicalizer::do_ArrayLength() after fix for JDK-8150102
shade
parents:
diff
changeset
|
154 |
} |