RFR: 8259954: gc/shenandoah/mxbeans tests fail with -Xcomp

Aleksey Shipilev shade at openjdk.java.net
Thu Jan 21 10:04:02 UTC 2021


On Thu, 21 Jan 2021 09:56:29 GMT, Eric Liu <github.com+10482586+theRealELiu at openjdk.org> wrote:

>> See the bug report for initial observation. The key thing is that the asynchronous GC notifications can arrive late, and they do arrive late with `-Xcomp`, because all that code is now waiting for compilation. The answer is to wait a bit smarter.
>> 
>> Additional testing:
>>  - [x] `gc/shenandoah/mxbeans` default mode
>>  - [x] `gc/shenandoah/mxbeans` with `-Xcomp`
>>  - [x] `gc/shenandoah/mxbeans` with `-Xint`
>
> test/hotspot/jtreg/gc/shenandoah/mxbeans/TestChurnNotifications.java line 167:
> 
>> 165:             Thread.sleep(1000);
>> 166:         }
>> 167:         Thread.sleep(5000);
> 
> I was wandering if it's necessary to handle the timeout by the code itself instead of delegating to jtreg? In the worst case, that's a really long time about 960000ms.

Yeah, I was wondering about the same when doing that chunk, but then argued to myself that timeout might be as well handled by jtreg. Mostly because in many cases JTREG_TIMEOUT_FACTOR is passed to control the machine-dependent behavior: slower/overloaded machines get larger timeout factors configured. Hardcoding the timeouts in the test would deprive us of this "feature".

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

PR: https://git.openjdk.java.net/jdk/pull/2179


More information about the shenandoah-dev mailing list