RFR: 8289764: gc/lock tests failed with "OutOfMemoryError: Java heap space: failed reallocation of scalar replaced objects"

Leonid Mesnik lmesnik at openjdk.org
Wed Jul 27 20:36:45 UTC 2022


On Wed, 27 Jul 2022 14:03:34 GMT, Ramkumar Sunderbabu <rsunderbabu at openjdk.org> wrote:

> Tested with all GC options

Changes requested by lmesnik (Reviewer).

test/hotspot/jtreg/vmTestbase/gc/lock/LockerTest.java line 51:

> 49:         public void run() {
> 50:             locker.lock();
> 51:             WhiteBox.getWhiteBox().fullGC();

Could you add some more work for GC here: add and free objects, arrays, strings and free them. Then call WB.GC to ensure that GC is triggered.
You could add the corresponding method in GarbageUtils and always use it instead eatMemory.

Might be call WB.YoungGC while generating garbage to put something into old gen as well as in young gen

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

PR: https://git.openjdk.org/jdk/pull/9658


More information about the hotspot-dev mailing list