RFR: 8295486: Inconsistent constant field values observed during compilation [v5]

Tobias Hartmann thartmann at openjdk.org
Tue Jan 24 13:51:35 UTC 2023


On Fri, 20 Jan 2023 18:41:14 GMT, Vladimir Ivanov <vlivanov at openjdk.org> wrote:

>> Tobias Hartmann has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   Fix to verification code
>
> src/hotspot/share/ci/ciObject.cpp line 183:
> 
>> 181:   for (int i = 0; i < _constant_values->length(); ++i) {
>> 182:     ConstantValue cached_val = _constant_values->at(i);
>> 183:     if (cached_val.off() == off) {
> 
> I'd also check that basic types matches (either with a runtime check or an assert).

I added an assert that immediately triggered because `ciArray::element_value_impl` creates a `ciConstant` with basic type `T_OBJECT` for a `T_ARRAY` array element. I fixed that code.

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

PR: https://git.openjdk.org/jdk/pull/11861


More information about the hotspot-compiler-dev mailing list