[11] RFR(S) 8205400: [Graal] compiler/jvmci/compilerToVM/DisassembleCodeBlobTest.java fails with can't be enqueued for compilation on level 4
Vladimir Kozlov
vladimir.kozlov at oracle.com
Tue Jun 26 16:04:53 UTC 2018
Thank you, Tobias
Vladimir
On 6/26/18 7:01 AM, Tobias Hartmann wrote:
> Hi Vladimir,
>
> this looks good to me.
>
> Best regards,
> Tobias
>
> On 23.06.2018 00:04, Vladimir Kozlov wrote:
>> http://cr.openjdk.java.net/~kvn/8205400/webrev.00/
>> https://bugs.openjdk.java.net/browse/JDK-8205400
>>
>> I was not able to reproduce the problem. I did 170 runs of the test with Graal in mach5. I can only
>> speculate what happen.
>> By default JVMCI and Graal are initialized only on first tier4 compilation request. Usually there
>> are hot methods which trigger such compilation and initialization before the test requests compilation.
>>
>> It is still possible that test's compilation request is the first.
>> The test asks blocking (BackgroundCompilation = false) compilation to wait when it complete [1].
>> But JVMCI code will unblock first compilation when JVMCI and Graal are not initialized yet [2].
>> As result execution continue before Graal's compilation finished (or even started) and
>> WB::compile_method() will return NULL value.
>>
>> To trigger eager JVMCI and Graal initialization flag -XX:+EagerJVMCI or -Xbatch
>> (-XX:-BackgroundCompilation) should be used to run test. And 2 of jvmci/compilerToVM/ tests which
>> use the same WB compilation API are using -XX:-BackgroundCompilation. I am suggesting to do the same
>> in 2 other tests.
>>
>> To find if this is really what happen I added error prints in WhiteBox::compile_method() which have
>> several cases when it can return false.
>>
>> Tested with tier1,tier2,tier3-graal,precheckin-comp
>>
>> [1]
>> http://hg.openjdk.java.net/jdk/jdk/file/d91a64467683/test/hotspot/jtreg/compiler/jvmci/compilerToVM/CompileCodeTestCase.java#l108
>>
>> [2]
>> http://hg.openjdk.java.net/jdk/jdk/file/d91a64467683/src/hotspot/share/compiler/compileBroker.cpp#l1082
>>
More information about the hotspot-compiler-dev
mailing list