RFR: 8263125: During deoptimization vectors should reassign scalarized payload after all objects are reallocated. [v2]

Vladimir Kozlov kvn at openjdk.java.net
Fri Mar 12 08:57:35 UTC 2021


On Fri, 12 Mar 2021 08:52:19 GMT, Vladimir Kozlov <kvn at openjdk.org> wrote:

>> Hello Vladimir,
>> 
>> your change looks good to me. You might want to add the refactoring Vladimir
>> suggested.
>> 
>> May I ask why there is a special case to reallocate a vectors payload at all. In
>> other words: why is the method VectorSupport::allocate_vector_payload_helper()
>> needed? Is it for support of VectorMask?
>> 
>> Thanks, Richard.
>
>> > I renamed incorrect eliminate_* names for methods which restore/reallocate objects and locks
>> 
>> Fully agree that `eliminate_allocations`/`eliminate_locks` are misleading, but `restore_*` still look a bit confusing to me.
>> What do you think about `rematerialize_objects`/`rematerialize_scalarized_objects`/`relock_objects`/`restore_eliminated_locks`?
> 
> I selected `rematerialize_objects` and `restore_eliminated_locks`.

> Thanks for the clarifications, Vladimir.
> 
> I agree that `VectorSupport::allocate_vector_payload` is not the right place to handle the problematic case.
> 
> Some cleanup suggestions: now you can remove `StackValue::create_stack_value()`-related code from`VectorSupport::allocate_vector_payload()`, replace `ScopeValue* payload` argument with `Location location`, and turn
> `location.type() == Location::vector` check into an assert.

I removed `create_stack_value()` code from `VectorSupport::allocate_vector_payload()` and added asserts for all possible cases I found.

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

PR: https://git.openjdk.java.net/jdk/pull/2924


More information about the hotspot-dev mailing list