Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
PojavLauncherTeam
GitHub Repository: PojavLauncherTeam/jdk17u
Path: blob/master/test/hotspot/jtreg/resourcehogs/compiler/intrinsics/string/TestStringIntrinsics2LargeArray.java
64560 views
1
/*
2
* Copyright (c) 2016, 2022, Oracle and/or its affiliates. All rights reserved.
3
* Copyright (c) 2016 SAP SE. All rights reserved.
4
* Copyright Amazon.com Inc. or its affiliates. All Rights Reserved.
5
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
6
*
7
* This code is free software; you can redistribute it and/or modify it
8
* under the terms of the GNU General Public License version 2 only, as
9
* published by the Free Software Foundation.
10
*
11
* This code is distributed in the hope that it will be useful, but WITHOUT
12
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
13
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
14
* version 2 for more details (a copy is included in the LICENSE file that
15
* accompanied this code).
16
*
17
* You should have received a copy of the GNU General Public License version
18
* 2 along with this work; if not, write to the Free Software Foundation,
19
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
20
*
21
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
22
* or visit www.oracle.com if you need additional information or have any
23
* questions.
24
*/
25
26
/*
27
* @test
28
* @bug 8254790
29
* @requires vm.bits == "64" & os.maxMemory > 8G
30
* @modules java.base/jdk.internal.misc
31
* @library /test/lib /test/hotspot/jtreg
32
*
33
* @build compiler.intrinsics.string.TestStringIntrinsics2
34
* @build sun.hotspot.WhiteBox
35
* @run driver jdk.test.lib.helpers.ClassFileInstaller sun.hotspot.WhiteBox
36
*
37
* @run main/othervm
38
* -mx8G
39
* -Xbootclasspath/a:.
40
* -Xmixed
41
* -XX:+UnlockDiagnosticVMOptions
42
* -XX:+WhiteBoxAPI
43
* -XX:+IgnoreUnrecognizedVMOptions
44
* -XX:MaxInlineSize=70
45
* -XX:MinInlineFrequencyRatio=0
46
* resourcehogs.compiler.intrinsics.string.TestStringIntrinsics2LargeArray
47
*/
48
49
package resourcehogs.compiler.intrinsics.string;
50
51
import java.lang.ref.Reference;
52
53
import compiler.intrinsics.string.TestStringIntrinsics2;
54
55
public final class TestStringIntrinsics2LargeArray {
56
public static void main(String[] args) throws Exception {
57
int[] hugeArray = new int[Integer.MAX_VALUE / 2];
58
TestStringIntrinsics2.main(args);
59
Reference.reachabilityFence(hugeArray);
60
}
61
}
62
63