RFR: 8297284: ResolutionErrorTable's key is wrong [v2]
Ioi Lam
iklam at openjdk.org
Tue Nov 29 01:49:03 UTC 2022
On Mon, 21 Nov 2022 18:04:00 GMT, Coleen Phillimore <coleenp at openjdk.org> wrote:
>> The resolution error table had a trick for the lookup key of adding constant pool index into constant pool address because that key was assumed to be in the range of the constant pool, so unique. For failed indy resolution, we also use the resolution error table and the index is not relative to the constant pool, so the key is potentially not unique. Created a Key class for the table and moved the cpool and index into that. Now the ResolutionErrorEntry just has the messages.
>>
>> Tested tier1-4.
>
> Coleen Phillimore has updated the pull request incrementally with one additional commit since the last revision:
>
> Matias comments
src/hotspot/share/classfile/resolutionErrors.hpp line 57:
> 55: // index of another entry in the table.
> 56: static const int CPCACHE_INDEX_MANGLE_VALUE = 1000000;
> 57:
Do we still need `CPCACHE_INDEX_MANGLE_VALUE` and `encode_cpcache_index(int index)`? The comment around that function says that `index` is negative, so it shouldn't be confused with regular cp indices which are non-negative.
-------------
PR: https://git.openjdk.org/jdk/pull/11244
More information about the hotspot-runtime-dev
mailing list