Skip to content
This repository was archived by the owner on Jul 17, 2024. It is now read-only.
/ jdk22u Public archive

Commit bc606a0

Browse files
committed
8323964: runtime/Thread/ThreadCountLimit.java fails intermittently on AIX
Backport-of: 3696765b7d1faec4bd23761a7a1b627d8903598d
1 parent 4ab7711 commit bc606a0

File tree

2 files changed

+18
-8
lines changed

2 files changed

+18
-8
lines changed

src/hotspot/os/aix/globals_aix.hpp

+8-7
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/*
2-
* Copyright (c) 2005, 2020, Oracle and/or its affiliates. All rights reserved.
3-
* Copyright (c) 2012, 2018 SAP SE. All rights reserved.
2+
* Copyright (c) 2005, 2024, Oracle and/or its affiliates. All rights reserved.
3+
* Copyright (c) 2012, 2024 SAP SE. All rights reserved.
44
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
55
*
66
* This code is free software; you can redistribute it and/or modify it
@@ -49,11 +49,12 @@
4949
"Allow VM to run with EXTSHM=ON.") \
5050
\
5151
/* Maximum expected size of the data segment. That correlates with the */ \
52-
/* to the maximum C Heap consumption we expect. */ \
53-
/* We need to know this because we need to leave "breathing space" for the */ \
54-
/* data segment when placing the java heap. If that space is too small, we */ \
55-
/* reduce our chance of getting a low heap address (needed for compressed */ \
56-
/* Oops). */ \
52+
/* maximum C Heap consumption we expect. */ \
53+
/* We need to leave "breathing space" for the data segment when */ \
54+
/* placing the java heap. If the MaxExpectedDataSegmentSize setting */ \
55+
/* is too small, we might run into resource issues creating many native */ \
56+
/* threads, if it is too large, we reduce our chance of getting a low heap */ \
57+
/* address (needed for compressed Oops). */ \
5758
product(uintx, MaxExpectedDataSegmentSize, 8*G, \
5859
"Maximum expected Data Segment Size.") \
5960
\

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

+10-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (c) 2020, 2022, Oracle and/or its affiliates. All rights reserved.
2+
* Copyright (c) 2020, 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
@@ -24,10 +24,19 @@
2424
/**
2525
* @test
2626
* @summary Stress test that reaches the process limit for thread count, or time limit.
27+
* @requires os.family != "aix"
2728
* @key stress
2829
* @run main/othervm -Xmx1g ThreadCountLimit
2930
*/
3031

32+
/**
33+
* @test
34+
* @summary Stress test that reaches the process limit for thread count, or time limit.
35+
* @requires os.family == "aix"
36+
* @key stress
37+
* @run main/othervm -Xmx1g -XX:MaxExpectedDataSegmentSize=16g ThreadCountLimit
38+
*/
39+
3140
import java.util.concurrent.CountDownLatch;
3241
import java.util.ArrayList;
3342

0 commit comments

Comments
 (0)