RFR: 8166554: Avoid compilation blocking in OverloadCompileQueueTest.java [v2]

Aleksey Shipilev shade at openjdk.java.net
Tue Sep 8 06:23:02 UTC 2020


On Mon, 7 Sep 2020 20:55:56 GMT, Evgeny Nikitin <enikitin at openjdk.org> wrote:

>> **Problem explanation**
>> 
>> 1. The stress test [uses 0.8 of allowed running
>> time](https://hg.openjdk.java.net/jdk/jdk/file/e10f558e1df5/test/hotspot/jtreg/compiler/codecache/stress/CodeCacheStressRunner.java#l40)
>> + 10 seconds, thus exceeding the limit; 2. 10 additional seconds are [given by the
>> VM](https://hg.openjdk.java.net/jdk/jdk/file/6db0cb3893c5/src/hotspot/share/runtime/vmOperations.cpp#l388) for stuck
>> compiler threads to finish; 3. Compiler threads aren't progressing due to the compilation being blocked; 4. Compilation
>> is blocked via WhiteBox by the test, its lockUnlock thread; 5. The lockUnlock thread doesn't unblock the compilation
>> because [it is a
>> daemon](https://hg.openjdk.java.net/jdk/jdk/file/e10f558e1df5/test/hotspot/jtreg/compiler/codecache/stress/Helper.java#l59),
>> it is stopped in the middle of the sleep.
>> **Solution**
>> 
>> Since the 'lockUnlock' is started via InfiniteLoop, it's not possible to un-daemon it. So I just turned the lockUnlock
>> method into a Thread descendant, which got joined in the end.
>
> Evgeny Nikitin has updated the pull request incrementally with one additional commit since the last revision:
> 
>   Interrupt LockUnlockThread before test finish, fix coding style issues.

Marked as reviewed by shade (Reviewer).

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

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


More information about the hotspot-compiler-dev mailing list