RFR: 8340733: Add scope for relaxing constraint on JavaCalls from CompilerThread [v3]
Tomáš Zezula
duke at openjdk.org
Fri Oct 4 16:02:38 UTC 2024
On Fri, 4 Oct 2024 15:31:52 GMT, Doug Simon <dnsimon at openjdk.org> wrote:
>> Tomáš Zezula has updated the pull request incrementally with one additional commit since the last revision:
>>
>> UseJVMCINativeLibrary check must be guarded by JVMCI_ONLY.
>
> src/hotspot/share/jvmci/jvmciCompilerToVM.cpp line 193:
>
>> 191: __block_can_call_java = CompilerThread::cast(thread)->can_call_java(); \
>> 192: } else { \
>> 193: __block_can_call_java = false; \
>
> For non-CompilerThreads, `__block_can_call_java` should be true I think since they are not affected by `-Xcomp` or `-Xbatch`. A TruffleCompileThread is such a thread.
For non-compiler thread the new value is never used because [CompilerThreadCanCallJava::update](https://github.com/openjdk/jdk/blob/f687c82ef9ede1d9d02ca0965c896bcf658c450a/src/hotspot/share/jvmci/jvmci.cpp#L58) does not modify the `CompilerThread::_can_call_java` value in this case.
However, using `true` may improve readability. I will change it.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/21285#discussion_r1787925558
More information about the hotspot-compiler-dev
mailing list