Skip to content

Commit 2ba6256

Browse files
committed
backport 9291abc6337f8cf480806f4b2996ec905b021704
1 parent 02a45b0 commit 2ba6256

File tree

3 files changed

+8
-6
lines changed

3 files changed

+8
-6
lines changed

test/hotspot/jtreg/runtime/Thread/TestAlwaysPreTouchStacks.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ public static void main(String[] args) throws Exception {
100100
vmArgs.add("-XX:-UseMadvPopulateWrite");
101101
}
102102
Collections.addAll(vmArgs, "TestAlwaysPreTouchStacks", "test");
103-
ProcessBuilder pb = ProcessTools.createLimitedTestJavaProcessBuilder(vmArgs);
103+
ProcessBuilder pb = ProcessTools.createTestJavaProcessBuilder(vmArgs);
104104
OutputAnalyzer output = new OutputAnalyzer(pb.start());
105105
output.reportDiagnosticSummary();
106106

test/hotspot/jtreg/runtime/cds/appcds/TestParallelGCWithCDS.java

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -116,8 +116,9 @@ static void test(boolean dumpWithParallel, boolean execWithParallel, boolean use
116116
} else {
117117
String pattern = "((Too small maximum heap)" +
118118
"|(GC triggered before VM initialization completed)" +
119-
"|(java.lang.OutOfMemoryError: Java heap space)" +
120-
"|(Initial heap size set to a larger value than the maximum heap size))";
119+
"|(Initial heap size set to a larger value than the maximum heap size)" +
120+
"|(java.lang.OutOfMemoryError)" +
121+
"|(Error: A JNI error has occurred, please check your installation and try again))";
121122
out.shouldMatch(pattern);
122123
out.shouldNotHaveFatalError();
123124
}

test/jdk/com/sun/jdi/ThreadMemoryLeakTest.java

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (c) 2023, Oracle and/or its affiliates. All rights reserved.
2+
* Copyright (c) 2023, 2024, Oracle and/or its affiliates. All rights reserved.
33
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
44
*
55
* This code is free software; you can redistribute it and/or modify it
@@ -26,8 +26,9 @@
2626
* @bug 8297638
2727
* @summary JDI memory leak when creating and destroying many threads
2828
*
29-
* @comment Don't allow -Xcomp or -Xint as they impact memory useage and number of iterations
30-
* @requires (vm.compMode == "Xmixed")
29+
* @comment Don't allow -Xcomp or -Xint as they impact memory useage and number of iterations.
30+
* Require compressed oops because not doing so increases memory usage.
31+
* @requires (vm.compMode == "Xmixed") & vm.opt.final.UseCompressedOops
3132
* @run build TestScaffold VMConnection TargetListener TargetAdapter
3233
* @run compile -g ThreadMemoryLeakTest.java
3334
* @comment run with -Xmx7m so any leak will quickly produce OOME

0 commit comments

Comments
 (0)