RFR: 8369021: A crash in ConstantPool::klass_at_impl [v2]

Jan Kratochvil jkratochvil at openjdk.org
Fri Oct 10 21:13:06 UTC 2025


On Fri, 10 Oct 2025 05:06:28 GMT, David Holmes <dholmes at openjdk.org> wrote:

>> Jan Kratochvil has updated the pull request with a new target base due to a merge or a rebase. The incremental webrev excludes the unrelated changes brought in by the merge/rebase. The pull request contains four additional commits since the last revision:
>> 
>>  - Merge branch 'master' into linkclass
>>  - Make an alternative fix in compute_enclosing_class
>>  - Revert "8369021: A crash in ConstantPool::klass_at_impl"
>>    
>>    This reverts commit 026fcb1b21729e41524169c7f78855e8794ddae2.
>>  - 8369021: A crash in ConstantPool::klass_at_impl
>
> src/hotspot/share/oops/instanceKlass.cpp line 3333:
> 
>> 3331: 
>> 3332:   // Wait until also outer_klass gets fully loaded.
>> 3333:   InstanceKlass* pool_holder = outer_klass->constants()->pool_holder();
> 
> This should just set `pool_holder == outer_klass`. When we parse a class we do:
> 
>  _cp->set_pool_holder(this_klass);
> this_klass->set_constants(_cp);
> 
> so `klass->constants()->pool_holder() == klass`. ??

I see now. I am withdrawing this patch before I get some updated patch verified with the customer.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/27595#discussion_r2422091665


More information about the hotspot-dev mailing list