On Thu, 8 Jan 2026 17:43:16 GMT, Kevin Walls <[email protected]> wrote:

> vmTestbase/CollectionCounters test still unreliable.
> Avoid -Xcomp and use WhiteBox to cause GC.

Recent changes in this test group are for a possible OOM failure and to make 
the iteration parameter behave as intended.
Historically the test did not print to show its iterations, but the count was 
set to zero, and it was not clear how much testing actually happened (sometimes 
none depending on timing, as the stresser.continueExecution() check was before 
any testing).

The iterations in this test do 3 activities that are meant to make the counters 
increase:
eatMemory,
System.gc,
MemoryMXBean.gc.

It performs 5 iterations now, which is not excessive but likely more than ever, 
and has now failed again.
The latest failure is on linux aarch64 with "-XX:+UseZGC -Xcomp", and is a 
failure after the eatMemory test on the final iteration.

(1)
Why test with -Xcomp?  That just adds timing complications.  Various tests that 
are timing sensitive avoid -Xcomp, and this should also.

(2)
This can also migrate to using WhiteBox like suggested in JDK-8373945 for a 
larger set of tests.

(3)
The "randomness" keyword looks wrong.
The eatMemory call used to fill with random content, but that didn't really 
matter as long as enough content was created.
Maybe it was always meant to be "intermittent".  But now it should be removed.

-------------

PR Comment: https://git.openjdk.org/jdk/pull/29122#issuecomment-3724989272

Reply via email to