On Mon, 26 Jun 2023 07:42:48 GMT, David Holmes <dhol...@openjdk.org> wrote:

> The eager loading seems reasonable, but I do not understand the details here. 
> In what way was loading failing? You still have to initialize `VMSupport` 
> before you can call methods on it, so that could also fail - though the code 
> does not seem to notice/handle this. ??

The usages of `vmSupport` below all use `JavaCalls:call_static` which takes 
care of linking and initializing the class.

> src/hotspot/share/jvmci/jvmciCompilerToVM.cpp line 585:
> 
>> 583: 
>> 584:   if (class_name->utf8_length() <= 1) {
>> 585:     JVMCI_THROW_MSG_0(InternalError, err_msg("Primitive type %s should 
>> be handled in Java code", str));
> 
> Seems unrelated to the fix at hand.

Yes, it's a minor fix up I noticed while making changes a few lines below. It 
just avoids a conversion of a `Symbol` back to a C string when the original C 
string is available.

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

PR Comment: https://git.openjdk.org/jdk/pull/14641#issuecomment-1606899412
PR Review Comment: https://git.openjdk.org/jdk/pull/14641#discussion_r1241766196

Reply via email to