RFR: 8317269: Store old classes in linked state in AOT cache [v5]

Ioi Lam iklam at openjdk.org
Fri Sep 5 04:38:11 UTC 2025


On Thu, 4 Sep 2025 19:12:08 GMT, Coleen Phillimore <coleenp at openjdk.org> wrote:

>> The problem is if `k` is the ObjArrayKlass of `[[I`, then `k->bottom_klass()` is `[I`, which is not an InstanceKlass. If we change the return type to `InstanceKlass*`, then we would have to return `nullptr`. However, that would make it more difficult to explain the following case (I've updated the comments):
>> 
>> 
>> bool SystemDictionaryShared::check_verification_dependency_exclusion(InstanceKlass* k, Symbol* dependency_class_name) {
>>   Klass* dependency_bottom_class = find_verification_dependency_bottom_class(k, dependency_class_name);
>>   if (dependency_bottom_class == nullptr) {
>>     // Dependency_class_name has not yet been loaded. This happens when the new verifier was checking
>>     // if dependency_class_name is assignable to an interface, and found the answer without resolving
>>     // dependency_class_name.
>>     //
>>     // Since this class is not even loaded, it surely cannot be excluded.
>>     return false;
>>   }
>
> This doesn't seem bad.  You could say "Not loaded or bottom class is not an instanceKlass."  Do you need to say what the verifier was doing here?

Usually not finding the constraint should lead to a rejection. However, this code does the opposite (it accepts a class if its constraint is not loaded), so a detailed explanation is needed.

(I've updated the comments again).

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

PR Review Comment: https://git.openjdk.org/jdk/pull/26754#discussion_r2324069523


More information about the hotspot-dev mailing list